If you’re running a WordPress website for more than a year now, then probably you’ll have encountered the “HTTP 500 Internal Server” by now. It’s one of the most common WordPress errors that can be a headache for WP beginners. However, there’s nothing to fret, as the error can be fixed. In this post, you’ll find all the solutions that will help you sort out the Internal server error on your WordPress site.
Why Internal Server Error Occurs in a WordPress Site?
The biggest problem with an Internal Server Error is that you can’t know where the error has exactly occurred. This error generally occurs in a WP powered site because of poorly coded plugin and/or theme functions. Other possible reasons that cause internal server error in WordPress are corrupted .htaccess file, and exceeding the PHP memory limit.
How to Troubleshoot The Internal Server Error?
1. Locate the Corrupt .htaccess File
In order to fix the internal server error in WordPress, the first thing that you should do is look out for the corrupted .htaccess file that may contain incorrectly configured to rewrite the rules. Once the file is located by you, make sure to rename your original .htaccess file to something like .htaccess_oldfile. Renaming the .htaccess file, however, requires FTP connection. So, after you’ve connected to FTP, login into your site and you’ll be able to see the .htaccess file in the directory where other folders like Wp-admin, wp-content, and a few others are located.
After renaming your .htaccess file, load your website to ensure whether the problem has been resolved or not. It’s great if you’re able to fix the error, but remember to change your default permalinks – prior to doing other things. This will help to create a new .htaccess file with improved rewrite rules, ensuring that your pages or posts won’t return 404 error. A word of caution make sure to keep a backup of your .htaccess file, as you might need them later.
If this solution doesn’t work for you, then you have a look at the other solution as discussed below.
2. Increase PHP Memory Limit
You may an Internal server error, when your site default PHP memory gets exhausted. And thus, you’ll have to increase the PHP memory limit to get this issue fixed. Note that in case you’re getting an Internal server error while attempting to login to your WordPress admin or while uploading any image in the admin panel, then you can increase the PHP memory limit with the help of below listed steps:
Open your wp-config.php (located in your WordPress install root directory). and add the following line of code:
In case you can access your PHP.ini file, then if you notice 32M instead of 64M, then add the following code to the file:
memory_limit = 64M ;
But in case you don’t have access to PHP.ini file, then add below mentioned code to your .htaccess file
php_value memory_limit 64M
If still the problem persists, then you should have a word with your web host.
3. Deactivate All Your Plugins At Once
In case you’re still not able to fix the Internal server error by using any one of the above solutions, then there are higher chances that the error occurred because of a plugin installed on your site or due to plugins conflict. Unfortunately, finding out such plugin can be a lot difficult, and hence, you’ll have to deactivate all your WP plugins at the same time. Now, check your site to verify whether the Internal server error still occurs or not. In case it does, then you’ll be assured that the plugin is causing the error. So, reactivate your plugins one at a time until you find the plugin that caused the error.
4. Re-Upload Your WordPress Core Files
If deactivating the plugin also didn’t help to sort out the problem, then re-upload your WordPress core files by simply re-uploading the wp-admin and wp-includes folder to a new WordPress install. This won’t remove any of your important information, but may resolve the Internal server error if any of your file was corrupted.
You may receive an Internal server error, also referred to as 500 Internal Server Error in your WordPress website. This error can cause panic among any beginner, as server is unable to locate where exactly the error has taken place. Some of the most common reasons that results in this error are corrupted .htaccess file and exceeding the default PHP memory limit of your site. Other than that, some other reasons that causes the Internal Server error could be installing poorly coded plugins, or because of some issue with the WordPress core files. This post will provide you with all the possible solutions that will most likely help you to fix the internal server error issue.
If you still have any issue then contact Designs2HTML Ltd a PSD to WordPress theme conversion company who had delivered 1500+ projects so far in WordPress conversions.