Steps to change XAMPP Apache Server Port
Step 1: Open XAMPP and start Apache. Here we can see that the default port is 80 (localhost:8080).
Step 2: Stop the running state of Apache, Click âconfigâ button.Here, we have to choose âhttpd.confâ for changing port.
Step 3: Access the Apache service in XAMPP to open the httpd.conf
configuration file in Notepad. Modify the listening port to your desired value, such as 81, at two locations within the file.
Find the line that says âServerName localhost:80â. Change the port here as well.
Step 4: Save the modifications and exit the âhttpd.conf file. Afterwards, restart the Apache service. Upon restarting, Apache will now be accessible on the newly designated port (e.g., 81).
By following these steps, we can successfully change the port of your XAMPP Apache server to avoid conflicts and ensure smooth operation.
How to Change XAMPP Apache Server Port?
XAMPP is a popular development environment that bundles Apache, MySQL, PHP, and other components to provide local web development. By default, the Apache server runs on port 80 for HTTP and port 443 for HTTPS. However, there may be instances where you need to change the default port configuration, such as when port 80 is already in use or to improve security. In this article, weâll provide a detailed guide on how to change the Apache server port in XAMPP.