Informática y Tecnología

XAMPP won’t start on your PC: real causes and solution in 2026

Post actualizado el día October 12, 2026 by DeiviSanzPlay

If when you open XAMPP the panel stays red, Apache won’t start, or MySQL crashes after two seconds, you’re not alone. It’s the most repeated breakdown among those who set up a local server for WordPress, Laravel, or any PHP project. And it’s almost never XAMPP’s fault: it’s port 80, the firewall, or a Windows service that has gotten ahead of it. Here’s the real solution, no beating around the bush.

Why XAMPP won’t start: the same three culprits every time

When XAMPP won’t start on Windows, 80% of the time there’s a port conflict. Port 80 is taken by Skype, IIS, Windows’ own web server, some print agents, and even Adobe applications. Port 3306 is hijacked by any MySQL or MariaDB already installed as a service.

The second culprit is the Windows firewall or an antivirus like Avast, Kaspersky, or Windows Defender in aggressive mode. They block httpd.exe and mysqld.exe without warning, and you just see the panel in red with no further explanation.

The third is a silly detail that trips up a lot of people: XAMPP installed in Program Files without administrator permissions. Windows won’t let it write logs or start services from there. Move it to C:xampp and run it as administrator.

Quick diagnosis: check the logs before touching anything

Before changing ports like crazy, open the XAMPP control panel and click Logs. There you have apache_error.log and mysql_error.log. In 90% of cases the first line tells you exactly what’s happening: “make_sock: could not bind to address 0.0.0.0:80” means port occupied; “Access is denied” means permissions; “InnoDB: Unable to lock” means there’s already a MySQL running.

This step is what separates those who fix XAMPP in five minutes from those who reinstall Windows unnecessarily. Don’t skip it.

How to find out which program is using port 80 on Windows

Open the command prompt as administrator and run this:

netstat -ano | findstr :80

You’ll get a list with the PID of the process using port 80. Then type tasklist | findstr [PID] and you’ll see the name of the culprit. It’s usually Skype (disable “Use ports 80 and 443” in its advanced options), IIS (stop the World Wide Web Publishing service), or the “Web Deployment Agent” service from Visual Studio.

If you don’t want to fight with anyone, change Apache’s port. It’s the cleanest solution and the one that causes the least trouble in the long run.

Change Apache and MySQL ports in XAMPP step by step

With the XAMPP panel closed, edit these files with Notepad++ or VS Code as administrator:

  • C:xamppapacheconfhttpd.conf: find Listen 80 and change it to Listen 8080. Also find ServerName localhost:80 and set it to 8080.
  • C:xamppapacheconfextrahttpd-ssl.conf: change Listen 443 to Listen 4433.
  • C:xamppmysqlbinmy.ini: if 3306 is taken, change port=3306 to port=3307. Careful, you’ll have to update the connection in your PHP projects (phpMyAdmin included).

Save, start XAMPP, and test. If Apache turns green, go to http://localhost:8080 and you’re done. This trick is the one that most often solves “XAMPP won’t start Apache or MySQL” in forums and support groups.

Run XAMPP as administrator and remove the firewall block

Right-click the XAMPP icon → Properties → Compatibility → check “Run this program as administrator”. Apply it also to xampp-control.exe and the Apache and MySQL .exe files.

If the firewall is giving you trouble, add an inbound rule for httpd.exe and mysqld.exe. I’ll tell you straight: disabling the entire antivirus is not a solution, it’s a patch that will blow up in your face. Make the exception properly and leave it at that.

What to do if XAMPP won’t open the control panel

When you double-click xampp-control.exe and absolutely nothing appears, the problem is almost always one of these:

  1. There’s already an instance open in the background. Open Task Manager and kill any xampp-control.exe process.
  2. The installation is corrupted. Reinstall XAMPP from the official website (apachefriends.org) by downloading the full installer, not the updater.
  3. The Visual C++ Redistributable is missing. XAMPP 8.x needs VC++ 2015-2022. If you don’t have it, the panel won’t start no matter what.

Another frequent cause in 2026: having XAMPP in a folder synced with OneDrive or on a network drive. Windows blocks .exe files in those locations. Move it to C:xampp without a second thought.

Specific errors: Apache crashes, MySQL won’t start, corrupted InnoDB

If Apache starts and crashes after two seconds, check whether you have an httpd.conf with duplicate modules or an incompatible PHP version. In recent XAMPP, each major PHP version requires its own binary; don’t mix folders.

If MySQL won’t start and the log says “InnoDB: File .ibdata1 was not found”, your database is corrupted. Solution: rename the C:xamppmysqldata folder to data_old, start MySQL (it will be created clean), and then recover your databases from data_old folder by folder. It’s tedious but it works.

Update XAMPP: the cause almost nobody checks

There are old versions of XAMPP (7.x, 8.0) with known bugs on Windows 11 24H2 and 25H2. If you’ve had the same installation for two years, the problem may simply be that you’re using obsolete software. Download the latest version from apachefriends.org, install it in a parallel folder, and migrate your projects. Don’t update on top: it breaks configurations.

And be careful, XAMPP is not meant for production. It’s a development environment. If you need a proper server, go with Docker, Laragon, or WSL2. Laragon, in fact, starts ports more intelligently and gets along better with Windows than XAMPP in many scenarios.

Operational summary: what to do in order

  1. Check the XAMPP panel logs.
  2. Check with netstat -ano | findstr :80 who’s using the port.
  3. Change Apache to 8080 and MySQL to 3307 if there’s a conflict.
  4. Run XAMPP as administrator and add firewall exceptions.
  5. Move the installation to C:xampp without OneDrive or strange paths.
  6. Install the Visual C++ Redistributable if the panel won’t open.
  7. Update XAMPP to the latest version if none of the above works.

With this, “XAMPP won’t start on my PC” stops being a mystery and becomes a problem solved in less time than it takes you to make a coffee. And if after all this it’s still failing, the problem isn’t XAMPP: it’s your Windows, and it’s time to repair it with sfc /scannow and DISM /Online /Cleanup-Image /RestoreHealth.