Fixing 500 Internal Server Error in WordPress
By Aj Khandal | Published: | 2 min read

This is a very common problem faced by developers and users while migrating a website or updating code. There are many reasons why this problem arises, and developers often waste a lot of time finding the solution. In this blog, I will tell you the main reasons and the ways to solve it.
Here are the main reasons for the 500 Internal Server Error in WordPress and their solutions:
1. Corrupted Files
This is the main reason for this error. It often occurs when we update our server, and some plugins do not support this WordPress update. For example, if we are running WordPress version 4.2 and the latest version of Contact Form 7, you will see that some functions are not defined in the older version, resulting in this error.
Solution
To check and fix this error, follow these simple steps:
- Rename your plugins folder located under
wp-content (e.g., rename plugins to plugins_old).
- Create a new, empty
plugins folder.
Now refresh the website and check if the error has been resolved. If it has been resolved, delete the empty folder and rename your old plugins folder back to the original (plugins).
After that, go into the plugins folder and rename the individual plugin folders one by one. In this way, you will be able to find the specific plugin causing the problem and you can remove it.
- If this issue is not resolved by the plugins, apply the same troubleshooting method to the themes folder (
wp-content -> themes).
2. Memory Limit
This is another common reason for this issue. This happens when we upload new plugins which require a higher PHP memory limit.
Solution
Go to your wp-config.php file located in the root folder and add the following line:
define('WP_MEMORY_LIMIT', '64M');
3. Corrupted .htaccess File
A corrupted .htaccess file can sometimes be the reason for this 500 internal server issue.
Solution
To resolve this, we need to rename our .htaccess file (e.g., to .htaccess_old) and then load our website. If it works fine, go to your WordPress Permalinks settings and click "Save Changes" to generate a fresh, original .htaccess file.
4. Missing Files
This problem typically comes up when we migrate our website to a new server. To rule out other issues, you should first complete the plugin troubleshooting step mentioned above.
Solution
To resolve this issue, we need to re-upload our website backup to ensure all core files were transferred correctly.