Solution to Solve XAMPP Access Denied on Windows

The events in XAMPP vary widely, but most of them are rare. Just one common problem and it keeps one thinking about why. That is the appearance of the XAMPP Access Denied error message, and sometimes it can also cause the program not responding.

An example of a full error notification looks like this:Error: Cannot Create File (directory) xampp-control.ini Access is denied

If you experience this problem, there is no need to worry, because the way to overcome it is very easy. That is just enough run XAMPP program as administrator. That way the notification will not reappear.

Fix XAMPP Access is Denied on Windows

So in total there are two ways that you can apply to overcome it. The first is to directly run the XAMPP program as an administrator. And the second is to disable UAC (User Access Control) in system settings.

1. Run XAMPP As Administrator

Basically XAMPP can be run even if not as an administrator provided that the installation directory is not on the C drive. However, problems may arise when you want to issue XAMPP, so the error notification will appear.

So the easiest solution is to always run XAMPP as Administrator, here’s how:

  1. Search XAMPP on Windows search.

    Search for XAMPP on Windows

  2. Then right-click on the XAMPP program.

    Resolving XAMPP Access Denied on Windows

  3. Select on option Run as Administrator.

  4. Permissions will appear, please continue click the button YES.

  5. Done, now XAMPP is running as administrator.

In addition to the above method, you can also do it directly on XAMPP shortcuts. Just go to the Properties section of the shortcut, then click the tab Customize and enable it in options Run this program as administrator. So every time you open XAMPP via a shortcut, the administrator permissions will appear immediately.

Also read: How to Fix .htaccess Not Working in XAMPP

2. Disabling UAC on Windows

UAC is very necessary on Windows to find out what programs are requesting admin access permissions. If this feature is turned off, as a result, the computer will not display permission notifications from programs that are opened, and are automatically approved immediately.

I don’t recommend this method because I think UAC is very necessary to review what programs ask for admin permissions. But if you still want to apply it, please follow the steps below:

  1. Type UAC on Windows search and ENTER.

  2. Then move the slider to the bottom.

    Disabling UAC on Windows

  3. The last step click the button OK.

After disabling UAC, you can immediately open XAMPP as usual and the error notification is guaranteed not to appear again.

Conclusion

In the process of installing the XAMPP program, there is information related to this. More precisely in the installation directory selection section, where XAMPP does not recommend installing it on the C drive due to this UAC problem.

So between the first or the second way, you can choose whichever you want. While I myself always use the first method. And if you have more questions about the two methods above, please comment directly.

Hopefully useful and good luck