How to Fix the XAMPP error “Apache Shutdown Unexpectedly”

Error: Apache shutdown unexpectedly :

If you use XAMPP software, then you must also have seen this “error: apache shutdown unexpectedly”. This is a very common error. Whenever you use any software related to the server or network, then such errors can be found for you to see. There can be many reasons for such errors in any software. But basically, such errors come due to the block of the network port of the software. In Xampp also, are caused by network port blocking in most of the cases. This is because many times we are also using some other software in the computer which works on the same network port on which the port is connected like – port 80 or port 443 etc. Hence this error comes due to a port clash.

Now we explain to you that if you see this error too, then how can you solve apache shutdown unexpectedly in xampp?

Solution for apache shutdown unexpectedly:

Step 1: Open Xampp software and click on the Apache server’s config button and then “Apache (httpd.conf)” button.  A text document named “httpd” will open.

Xampp Apache server httpd file

Step 2: Press Ctrl + H key for Replace window. Type 80 in the “Find What” text box and type a number greater than 1024 in the “Replace with” text box. For example, let me type “7882” here. After this, click on the “REPLACE ALL” button.

Xampp Apache server httpd file port

Step 3: Save these changes by pressing Ctrl + S or from the File à Save option and close the document.

Step 4: Now again go to the XAMPP control panel by double-clicking on the Xampp icon. Click on the config button of Apache. Now you click on the “Apache (httpd-ssl.conf)” option.

Xampp Apache server httpd-ssl file

Step 5: A text document named “httpd-ssl” will open. Press Ctrl + H key for Replace window. Type 443 in the “Find What” text box and here also type a number greater than 1024 in the “Replace with” text box. For example, let me type “8278” here. After this, click on the “REPLACE ALL” button.

Xampp Apache server httpd-ssl file port

Step 6: Save these changes by pressing Ctrl + S or from the File à Save option and close the document.

Step 7: Restart Your Xampp. Now you will be able to use the XAMPP software without apache error.

Leave a Comment