Are you seeing 500 internal server error in WordPress? Internal server error is one of the most common WordPress errors. Since the error 500 doesn’t give any other information, many beginners find it quite frustrating. In this blog, we will explain you several methods to fix internal server error 500 in WordPress.
Note: Before trying these solutions, we highly recommend backing up your WordPress site just to be on the safe side should anything go wrong
Causes of 500 Internal Server Error in WordPress
The WordPress 500 internal server error in WordPress can be caused by a number of issues such as:
- Corrupted .htaccess file
- PHP memory limit issues
- Problematic plugin(s)
- Corrupted WordPress core files
Soluton To Repair 500 Internal Server Error on Your WordPress Site
Now, let’s go over these causes one by one and outline a solution for each.
Corrupted .htaccess File
More often than not, a corrupted .htaccess file throws the internal server error in your face.
- .htaccess (short for Hypertext Access) is a configuration file used by your web server to control the directory it lives in (in this case your WordPress directory) and all sub-directories under that directory.
- To determine if a corrupted .htaccess file is the cause of the WordPress 500 internal server error on your site, we begin the diagnosis by renaming your existing .htaccess file.
Renaming .htaccess
- Login to your WordPress directory (the folder where your site lives) using FTP. You’ll know you are in the right directory if you see sub-folders such as wp-content, wp-includes and wp-admin.
- In most hosting environments, your WordPress directory site is usually the Home or Public_html directory. If you installed WordPress on a sub-domain such as yoursite.com/someurl, your WordPress directory is someurl.
- Next, locate your .htaccess file and right-click on it. Next, choose Rename. Rename your .htaccess file to something like .htaccess_old.
- After renaming your .htaccess file, reload your site to see if this solution fixes the 500 internal server error. If you can no longer see the internal server error, you can pop the bubbly.
Recreating .htaccess File
- Next, login to your WordPress admin dashboard, navigate to Settings -> Permalinks and click the Save button at the bottom of the screen
- Saving your permalinks creates a new .htaccess file for you automatically.
If the 500 error persists, scroll down to discover more solutions.
PHP Memory Limit Issues
At times, you could be getting the 500 internal server error in WordPress because you are exhausting your PHP memory limit. Fixing PHP memory limit issues is as easy as pie.
Note: Increasing your PHP memory limit can also fix the memory exhausted error, which is as baffling as the internal server error.
Increasing PHP Memory Limit for WordPress
Sometimes internal server error can happen if you are exhausting your PHP memory limit. Use our tutorial on how to increase PHP memory limit in WordPress to fix that.
If you are seeing the internal server error only when you try to login to your WordPress admin or uploading an image in your wp-admin, then you should increase the memory limit by following these steps:
- Create a blank text file called php.ini
- Paste this code in there: memory=64MB
- Save the file
- Upload it into your /wp-admin/ folder using FTP
Several users have said that doing the above fixed the admin side problem for them. If increasing the memory limit fixed the problem for you, then you have only fixed the problem temporarily. You still need to find the cause that is exhausting your memory limit.
This could be a poorly coded plugin or even a theme function. We strongly recommend that you ask your WordPress web hosting company to look into the server logs to help you find the exact diagnostics.
If increasing the PHP memory limit did not fix the issue for you, then you are in for some more troubleshooting.
Internal Server Error When Accessing Admin Area
As long as we’re talking about memory limits, it’s important to point out that you could see the 500 internal server error only when you try to upload an image or login to your WordPress admin area.
If this is the case, you can increase the memory limit by following these steps:
- Using preferred text editor, create a new file and add this code in there: memory=64MB
- Save the file as php.ini. Ensure you get the extension (.ini) right by choosing All types in the Save as type field:
- Upload this file to the wp-admin sub-folder within your WordPress directory using FTP.
Note: Fixing PHP memory limit using the php.ini file only works for localhost installations or/and WordPress VPS hosting. Use the wp-config.php file method above if you have 000webhost’s free WordPress hosting.
Increasing your PHP memory limit might fix the WordPress 500 internal server error, but it’s just a temporary fix since it means something on your site is eating up your server resources. For a complete diagnosis, you might need to dig into your error logs.
But even if increasing PHP memory limits doesn’t fix this error, it is time to check whether the problem lies in your plugins.
Deactivate All WordPress Plugins
The WordPress 500 internal server error can be the result of a faulty plugin or two conflicting plugins. To tell if a plugin is the root of the error, you need to deactivate all of them first.
Login to the WordPress directory. Open the wp-content folder and locate the plugins folder
- Rename the folder to something like plugins_old to deactivate all plugins at once. Don’t worry, you won’t break your site or lose any plugin.
- Reload your site to see if this solution fixes the internal server error. If so, it’s time to eliminate the problematic plugin.
- Rename plugins_old back to plugins and login to your WordPress admin dashboard. Next, activate your plugins one by one while refreshing your site each time until the error reappears.
- If you re-activate a plugin and the internal server error reappears, it means the last plugin is the culprit. Just delete the responsible plugin via FTP and notify the developer of the error.
Corrupted WordPress Core
Now if all the other solutions fail, perhaps the 500 internal server error in WordPress is caused by corrupted WordPress core files.
While this is rarely the case, things break all the time. To repair your WordPress core files, you must upload fresh versions of wp-admin and wp-includes folders.
How To Upload Fresh Versions Of WP-Admin and WP-Includes Folders
- Head over to WordPress.org and download a fresh version of WordPress
- Extract files from the WordPress .ZIP archive.
- Inside the WordPress folder locate the wp-admin and wp-includes folders.
- Login to your WordPress directory via FTP and upload the new wp-admin and wp-includes folders overwriting the older versions
Refresh your site to see if this fixes the error. Wait – did you just say you’re still seeing the 500 internal server error in you Wordpress? I know it's too annoying but don't worry we will figure it out in next method but in that case you can call on Wordpress support number 11888-588-7141.
Well, you can use WordPress built-in debugging tool feature to figure out what’s causing this error.
Debugging WordPress
Enabling WordPress debugging mode allows you to write all errors to a file called debug.log that is stored inside the wp-content folder.
To enable debugging:
- Login to your WordPress directory via FTP and download the wp-config.php file
- Open wp-config.php file and add the following code just before the line that says /* That's it, stop editing! Happy blogging */ :
- define ('WP_DEBUG', true);
- define ('WP_DEBUG_LOG', true);
- define ('WP_DEBUG_DISPLAY'. false);
- @ini_set ('display_errors', 0);
- Save your changes and upload wp-config.php to your WordPress directory overwriting the older version
Now, reload your site to trigger the error. Open your WordPress directory, navigate to the wp-content folder and open debug.log. If you have a developer friend, they can help you to decipher the errors. We can also lend a hand whenever you’re stuck, so don’t hesitate asking your questions in the comment section or dial phone number.
The WordPress 500 internal server error is mainly the result of a bad .htaccess file or exhausting your PHP memory limit. Did any of the above solutions fix the 500 internal server error for you? If so, please let us know in the comment and for any further information or queries you contact us at anytime like at 1888-588-7141.
Google Searches Related to Internal Server Error 500 in WordPress
- how to fix 500 internal server error
- 500 internal server error wordpress godaddy
- is currently unable to handle this request.
- wordpress intermittent 500 error
- wordpress multisite 500 error
- wordpress debug 500 internal server error
- 500 internal server error php