Blog

Solved – How to fix the blocked Port Error in XAMPP

The error you’re getting probably reads something like this:

[Apache] Status change detected: running
[Apache] Status change detected: stopped
[Apache] Error: Apache shutdown unexpectedly.
[Apache] This may be due to a blocked port, missing dependencies,
[Apache] improper privileges, a crash, or a shutdown by another method.
[Apache] Press the Logs button to view error logs and check
[Apache] the Windows Event Viewer for more clues
[Apache] If you need more help, copy and post this
[Apache] entire log window on the forums

This error generally occurs due to a blocked port 80.

Solution 1 –

To find the application that is using port 80 (probably Skype) and change it to use some other port.

Open Skype.

Tools -> Options -> Advanced -> Connection.

Uncheck the β€œUse port 80 and 443 for alternatives for incoming connections” checkbox

Sign Out and Close all Skype windows. Try restarting your Apache.

 

But you may not have control of that.

 

Solution 2 –

You can change Apache to use a different port. Here’s how:

  • Go to Xampp Control Panel:-

Click on Config by Apache and selectΒ httpd.conf:

 

  • Find β€œListen 80” and change it to β€œListen 8080”.
  • Find β€œServerName localhost:80” and change it to β€œServerName localhost:8080”.

 

If you’re also running SSL, you’ll need to changeΒ httpd-ssl.conf:

 

  • Find β€œListen 443” and change it to β€œListen 4433”.
  • Find β€œ<VirtualHost _default_:443>” and change it to β€œ<VirtualHost _default_:4443>”.
  • Find β€œServerName localhost:443”. It’s possible that this hasn’t been set up yet and it reads β€œServerName www.example.com:443”. In any case, change it to β€œServerName localhost:4443”.

In the XAMPP Control panel, click on Config:

 

Click on Service and Port Settings and change the Main Port to 8080 and the SSL Port 4433.

 

Click on Save. Stop and Start Apache.

 

Click the Admin button by Apache and it should open up the XAMPP home page in your browser.

6 Steps to Install Magento 2.4.3 on XAMPP Windows Using Composer

That’s it. Hope this is helpful. Do comment below and let me know the feedback.

2 thoughts on “Solved – How to fix the blocked Port Error in XAMPP

Leave a Reply

Your email address will not be published. Required fields are marked *

πŸš€ Let’s Connect on LinkedIn! πŸš€

Want to level up your skills and knowledge? πŸš€
Follow us on LinkedIn to get:
βœ… Expert insights on business growth
βœ… Daily tips to sharpen your skills
βœ… Exclusive updates from The Coach SMB

Let's grow together!