How to Easily Fix :"500 Internal Server Error" in WordPress
If you want to easily fix WordPress 500 internal server error, then you’ll love this detailed guide.

You shouldn’t panic when you see the internal server error on your WordPress site. It doesn’t matter if your site is hosted on 000webhost free web hosting or any other hosting provider.
Even though this error doesn’t tell you what’s wrong, you can easily fix this error with the solutions in this post.
Note:Before trying these solutions, we highly recommend backing up your WordPress site just to be on the safe side should anything go wrong.
Keeping backups is of great importance, and it’s a good habit to form. By the way, if you experience the 500 internal server error (or any other, for example, 502 Bad Gateway) after making recent changes to your site, you can simply restore a backup you created prior to the changes.
That aside, let’s get started.
Table of Contents [hide]
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
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 .htaccessfile.
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 -> Permalinksand click the Save button at the bottom of the screen:

Saving your permalinks creates a new .htaccess file for you automatically.
If the error persists, read on 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.
Pro Tip: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
You can increase your PHP memory limit by editing your wp-config.php file that is inside your WordPress directory (the same directory where the .htaccess file lives).
- Login to your WordPress directory and download wp-config.php file to your computer:

- Open the wp-config.php using a code editor such as NotePad++ or Atom and add the following code just above the line that says
/* That's all, stop editing! Happy blogging. */:- define ('WP_MEMORY_LIMIT', '300M');
This code instructs WordPress to increase the PHP memory limit to 300 MB. - Next, save the changes and upload wp-config.php to your WordPress directory:
Don’t hesitate to overwrite the existing wp-config.php file:
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.
Problematic Plugin(s)
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?
- 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?
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.
_______________________________________
2nd Method
What Causes Internal Server Error in WordPress?
Internal server error is not specific to WordPress. It can happen with any website running on a web server. Due to the generic nature of this error, it does not tell the developer anything.
Asking how to fix an internal server error is like asking your doctor how to fix the pain without telling them where the pain is.

Internal server error in WordPress is often caused by plugin or theme functions. Other possible causes of internal server error in WordPress that we know of are: corrupted .htaccess file and PHP memory limit.
We have also heard internal server error only showing up when you are trying to access the admin area while the rest of the site works fine.
That being said, now let’s take a look at how to go about troubleshooting the internal server error in WordPress.
Checking for Corrupt .htaccess File
The first thing you should do when troubleshooting the internal server error in WordPress is check for the corrupted .htaccess file.
You can do so by renaming your main .htaccess file to something like .htaccess_old. To rename the .htaccess file, you will need to login to your site using FTP or File Manager app in your hosting account’s cPanel dashboard.
Once you connected, the .htaccess file will be located in the same directory where you will see folders like wp-content, wp-admin, and wp-includes.

Once you have renamed the .htaccess file, try visiting your site to see if this solved the problem. If it did, then give yourself a pat on the back because you fixed the internal server error.
Before you move on with other things, make sure that you go to Settings » Permalinks page in WordPress admin area and click the save button without making any changes. This will generate a new .htaccess file for you with proper rewrite rules to ensure that your post pages do not return a 404 error.
If checking for the corrupt .htaccess file solution did not work for you, then you need to continue reading this article.
Increasing the PHP Memory Limit
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.
Deactivate all Plugins
If none of the above solutions worked for you, then this error is most likely being caused by a specific plugin. It is also possible that it is a combination of plugins that are not playing nice with each other.
Sadly, there is no easy way to find this out. You have to deactivate all WordPress plugins at once.
Follow the instructions in our guide on how to deactivate all WordPress plugins without WP-Admin.

If disabling all plugins fixed the error, then you know it is one of the plugins that is causing the error.
Simply go to the WordPress admin area and click on ‘Plugins’. Now you need to reactivate one plugin at a time until you find the one that caused the issue. Get rid of that plugin, and report the error to the plugin author.
Re-uploading Core Files
If the plugin option didn’t fix the internal server error, then it is worth re-uploading the wp-admin and wp-includes folder from a fresh WordPress install.
This will NOT remove any of your information, but it may solve the problem in case any file was corrupted.
First you will need to visit the WordPress.org website and click on the Download button.

This will install WordPress zip file to your computer. You need to extract the zip file and inside it you will find a wordpress folder.
Next you need to connect to your WordPress website using an FTP client. Once connected go to the root folder of your website. It is the folder that has wp-admin, wp-includes, wp-content folders inside it.
In the left column open the WordPress folder on your computer. Now you need to select wp-includes and wp-admin folders and then right-click and select ‘Upload’.

Your FTP client will now transfer those folder to your server. It will ask you whether you would like to overwrite the files. Select ‘Overwrite’ and then select ‘Always use this action’.

Your FTP client will now replace your older WordPress files with newer fresh copies. If your WordPress files were corrupted, then this step will fix the internal server error for you.
Ask your Hosting Provider
If all methods fail to fix internal server error on your website, then it is time to get some more help. Contact your web hosting support team and they will be able to check the server logs and locate the root cause of the error.
Tag:
wp error , wp http error 500 , wp error log , wp error establishing a database connection , wp-admin error 500 , crown wp 3000 error code 857 , crown wp 3000 error codes , is_wp_error not working , wp booster error , wp cli error establishing a database connection , wp database error , wp error 404 , wp error 500 , wp error fix , wp error reporting , wp login error , wp network error domain error-994 , wp-login error 500 , wp_error could not be converted to string , wp http error couldn't connect to host , wp http error curl error 77 .
Thank you for sharing…………. WordPress Developer Sydney Solving WordPress 500 Internal Server Error.
ReplyDeleteWordPress 500 Internal Server Error