If you are seeing 500 Internal server error on WordPress blog then this guide will help you to troubleshoot the error in the easiest way.
When something goes wrong on your WordPress core file in your web server , you will encounter internal server error which will be frustrating. Generally, in WordPress this error occurs by installing or updating the faulty plugin and theme.
There can also be the possibility of corrupted .htaccess file which is configuration file in your web server. Another reason for this is error is limited PHP memory set in your web server.
This error is one the common error that every blog may experience. Because the error messages do not indicate the specific path or files that need to be fixed, it can be overwhelming to find out the exact issue.
In these tutorials you can troubleshooting 500 Internal Server Error step by step until your website get back to online.
Troubleshooting the 500 Internal Server Error Step by Step:
- Replace or Fix .htaccess File in your Web Server.
- Increase PHP Memory Limit
- Deactivate all the Plugins
- Reinstall WordPress Core Files
Step-1: Replace or Fix .htaccess File in your Web Server.
The one of the common troubleshooting for 500 Internal Server Error is to fix WordPress configuration file called .htaccess. It is located in your root folder of the web sever and can access using FTP client “FileZilla” or “CoreFTP”.
Download FileZilla and install into your computer. Once downloaded, connect to the server using FTP credential provided by your hosting company. FileZilla have two sections PC section and Server Section.
From Server section, double click public_html folder to open. You will find WordPress core files and folders like wp-admin, wp-content and wp-includes in the same location you will also find .htaccess file.
Find .htaccess file in the same location. Right click on .htaccess file and rename the file name e.g. .htaccess-fix.
Go back to your web browser and load your site, if your site load without error then you have fixed the 500 internal server error successfully. Now, you have to login to WordPress dashboard and update the Permalink under Settings which will generate new .htaccess file and avoid 404 page error in your blog pages and posts.
Login to WordPress Dashboard and Click on Permalinks under Settings. Click on Save Changes without changing the any settings.
If you still see 500 Internal Server Error then follow the next step.
Step-2: Increase PHP Memory Limit
Internal Server Error can also cause by the limited PHP Memory. You can fix this error by increasing PHP memory by editing wp-config.php files located in the root directory of the web server.
Connect to your web server using FileZilla. Open public_html at the right side. You will see the file called wp-config.php file in the same location where your wp-content and wp-admin folders are located.
Right click on wp-config.php file and click on View/Edit.
Your file will open in file editor where you have to add the line of code below <?php tag.
After adding the line of code, save the file and reload your website. If the issue is fixed by increasing the PHP memory limit then Great! But you still have to find the problem which plugins or themes is eating the PHP memory and remove or replace it from your website.
If increasing PHP memory limit did not fix the error then follow the next step.
Step-3: Deactivate Plugins
Faulty plugins can also cause 500 Internal Server Error. You can deactivate all the plugins renaming the plugins folder located in root directory of the web server. Connect to the server using FileZilla and double click on public_html folder to open where you will see the WordPress core files and folders.
Open wp-content folder and you will find plugins folder. Right click on the plugins folder and click on rename then type any name e.g. plugins-fix. These will deactivate all the installed plugin in your WordPress site.
You can refer this guide on How to deactivate all the WordPress plugins for more details.
Once all the plugins deactivate you can try loading your site, if everything goes well and website loads without error then you know the issue is cause by one of the plugins.
To find the faulty plugin login to WordPress dashboard and activate the installed plugins one by one until your site breaks. Once you figure out which plugin is creating issue you can remove or replace it from your website.
Step-4: Reinstall WordPress Core Files
If above troubleshooting does not fix the error, then you should reinstall wp-admin and wp-include folder from the fresh copy of WordPress file. Re-uploading those folders will not affect your blog data.
Use this link to Download WordPress file and save it on the desktop.
Once downloaded you will see WordPress file in ZIP format. Right click on the file and click on extract here. It will extract and create separate WordPress folder on the desktop.
Now, Open FTP client FileZilla and connect to your web server. From Server Section, click on public_html to open root directory of your website where you will find WordPress core files and folders e.g. wp-admin, wp-content, wp-includes.
From the PC section expand Desktop and select WordPress folder. Select wp-admin and wp-includes holding CTRL key then right click on the folders and click on Upload.
FileZilla will start transferring those folders to your web server which will replace existing wp-admin and wp-content folder in the server. You will see the pop up to overwrite the folders. Click on Always use this action and click ok button.
Get Help from your Hosting Provider.
In-case above troubleshooting steps did not solve the issue then you should ask your hosting provider through support ticket or live chat to fix the issue.
We hope this guide have helped you to fix 500 internal server error in WordPress website. You may also like to see guide on fatal error : maximum execution time exceeded.