How to Fix the 500 internal server error on WordPress

The 500 Internal Server error it is the most common and general error, that will be shown when there’s a problem with the server or with the WordPress file system. It is the most unhelpful and nondescript bane of web developers everywhere. It’s a catchall error message that can literally mean anything.

Let’s have a look how to troubleshoot this error.

If you are seeing this error from time to time, this most likely means that there is not enough PHP memory on your site. In this case please increase your site’s PHP memory,

To do so, access your site’s folders via a File Manager or via FTP (see Using FTP client bellow). Locate and edit the wp-config.php file.

Add the following line:

define('WP_MEMORY_LIMIT', '256M');

Make sure it is added right above this line

 /* That's all, stop editing! Happy blogging. */ if it already there changed the 64M to 256, if it is not, place the following line inside the file:

If this line is already there changed the MB value to a higher one.


If, on the other hand, the 500 error is showing up all the time, this can be caused by a conflicting PHP code on your site.

Backup your site

I am highly recommending to backup your site before proceeding this troubleshooting.  To find the core of the issue we will make changes in the root directory of the site. So if something will go wrong, you can always restore it.

Deactivate all your plugins

If you have access to your site from the back end, go to Plugins > All Plugins. Select all your plugins, choose “Deactivate” from Bulk Options and Apply changes.

Check if the 500 Internal Server error is gone from the front page. If it is gone, activate one plugin at the time to find out which one is causing this error.

If you don’t have access to the backend of your site, use FTP client of File Manager on your cPanel to access WordPress directory files.

Using FTP client

If you are already familiar with the FTP client, please skip this section.

If you are a PC user, please download FileZilla FTP Client from here.

For Mac Users try:

1.  Cyberduck; free FTP software designed for Macs
2.  Transmit – FTP software you purchase designed for Macs

Once you install FileZilla, use your domain name, username, and password to access your host’s file manager.

And you are ready to go!

Access your site from the cPanel

First, log into cPanel. In the Files section, click on the File Manager icon.

Click to expand the public_html folder, nad you will see your WordPress site directory root.

Deactivate your plugins manually

Navigate to the /wp-content/plugins folder and rename the plugins folder to plugins.deactivate. All the plugins will be deactivated after this.

Check your front end if it is working, if it is working, if it is, rename back the plugins.deactivate to plugins. Open the plugins folder and start renaming each plugin folder one by one till the error disappears from your site. This will allow you to reactivate each plugin individually to isolate the offending plugin and resolve the 500 Internal Server Error.

Check the .htaccess file

Open your WordPress root directory in FileZilla or your preferred FTP client. This is typically called public_html. Locate the .htaccess file, download it to your computer to have a backup and delete it from your directory. Try to load your site again, if your site is back, congratulations!

Now, go into your WordPress admin area. Hover over Settings, and select Permalinks. Scroll down to the bottom of the page, and click Save Changes.

Ask your Hosting Provider

If nothing works, then you need to get in touch with your hosting provider. By looking at the server logs, they should be able to get to the bottom of things.

Leave a Reply

Your email address will not be published. Required fields are marked *