Post actualizado el día October 24, 2026 by DeiviSanzPlay
Troubleshooting Common XAMPP Errors: A Practical Guide
XAMPP is a widely used local development environment for testing web applications with Apache, MySQL, PHP, and Perl. Despite its popularity, users often encounter errors that interrupt their workflow. In this article, we’ll explore the most common causes and how to fix them effectively.
Error: Port 80 in use
When starting Apache, it’s common to see a message like “Problem detected: Port 80 in use by ‘Unable to open process’.” This happens because another program (Skype, IIS, VMware) is using port 80. To fix it, you can change Apache’s port in the httpd.conf file (for example, to 8080) or stop the conflicting service. Remember to update the access URL to http://localhost:8080.
Error: MySQL won’t start (port 3306 occupied)
Similar to the previous case, MySQL may fail if port 3306 is in use. Check whether another MySQL or MariaDB server is running. From the XAMPP Control Panel, stop the service and start it again. If the issue persists, edit my.ini and change the port to 3307, then update your applications’ configuration.
403 Forbidden error when accessing localhost
This error indicates that Apache doesn’t have permission to access the files in the root directory. Verify that the path in httpd.conf (DocumentRoot directive) is correct and that the folder permissions allow reading. On Windows, make sure the htdocs folder isn’t blocked by the system.
“Access denied for user ‘root’@’localhost'” error in phpMyAdmin
This problem arises when the root password in MySQL doesn’t match the one configured in phpMyAdmin. Open the config.inc.php file in the phpMyAdmin folder and verify the credentials. If you’ve forgotten the password, you can reset it from the command line with mysqladmin -u root password new_password.
Missing extension error: “Fatal error: Uncaught Error: Call to undefined function…”
This occurs when PHP tries to use an extension that isn’t enabled (for example, mysqli or gd). Fix it by editing php.ini and uncommenting the corresponding line (remove the leading semicolon). Then restart Apache from the XAMPP panel.
Timezone error in PHP
PHP may display warnings about the timezone not being configured. Open php.ini, find the date.timezone directive, and set it to your timezone, for example date.timezone = “America/Mexico_City”. Save and restart the service.
Error starting Apache: “Cannot load modules/libphp7.so”
This message is usually due to an incomplete installation or a PHP update without adjusting the paths. Check the httpd.conf file and make sure the LoadModule php7_module line points to the correct path inside the php folder. If you’re using a different version, adjust the number.
MySQL connection error from PHP
If your PHP script can’t connect to MySQL, verify that the service is running, that the host is localhost, and that the credentials are correct. Also check that the mysqli extension is enabled in php.ini.
Additional tips
- Run XAMPP as administrator on Windows to avoid permission issues.
- Keep XAMPP up to date to benefit from the latest fixes.
- Check the Apache (error.log) and MySQL (mysql_error.log) logs for detailed clues.
- If nothing works, consider reinstalling XAMPP after backing up your projects and databases.
With these solutions, you’ll be able to resolve the most common errors and continue developing without setbacks.