Have you ever tried to access your WordPress site and received an “ Internal Server Error” or similar message?
This may be happening to you right now:
This is a terrible mistake because just like making the mistake of establishing a database connection, your website will completely disappear.
However, don’t worry too much. The Internal Server Error message is fixable and your WordPress site data should still be intact.
In this article, you’ll learn:
- What is *an internal server error , and *some of its causes.
- How to fix internal server error in WordPress .
What does the "Internal Server Error" message mean?
An Internal Server Error (sometimes also called a 500 Internal Server Error) is a generic error message given out when a server encounters a problem. It basically tells you that "something" went wrong... but it doesn't specify what that "something" is.
This isn't a satisfying explanation - but then again, it's not a very specific bug.
What causes an "Internal Server Error" message?
Because this error message is so broad, there is no single problem that can cause this error message.
For WordPress, the most common reasons are:
- Corrupted .htaccess file.
- Plugin issue.
- The PHP memory limit was reached.
- Corrupted WordPress core files.
We'll show you how to fix all of these issues. However, if you want to narrow down the problem quickly, consulting your server's error log is an effective way to diagnose the source of the problem.
If your host uses cPanel, you can view the error log by going to your cPanel dashboard and clicking "Error Log":
Unfortunately, as you can see from the image below, these error logs are not always the most user-friendly documentation:
If there is nothing obvious in the error log, you can:
- Please consult your console support for help understanding possible issues.
- Jump right into some common fixes I’ll outline below.
NOTE: Here are the hosts that are confirmed to offer cPanel hosting:
How to Fix “Internal Server Error” in WordPress
Here are some of the most common ways to fix this message in WordPress. I recommend starting at the top (Potential Fix #1) and working your way down.
Potential Fix 1: Generate a new .htaccess file
The .htaccess file is a configuration file for your web server. WordPress uses it to set up your permalink structure, among other things.
Because it controls your web server's configuration, even a small mistake in your .htaccess file can result in something like an Internal Server Error message.
Thankfully, this problem is easy to fix – all you need to do is force WordPress to generate a new .htaccess file.
Here’s how:
Step 1: Rename the existing .htaccess file.
First, you need to rename your existing .htaccess file. You can do this in the following ways:
- Connect to your website via FTP. You can use FileZilla to do this.
- Use cPanel's built-in file manager tool.
I'm going to show you the process using a file manager , as that's easiest for most users. But no matter which method you use, the core principles are the same.
You can access the File Manager directly from your cPanel dashboard :
Once your file manager is open , look for the .htaccess file in your website’s root directory .
Right-click it and select Rename:
Rename it to something like ".htaccess_old".
Now, all you need to do is create a new .htaccess file to replace it.
Step 2: Generate a new .htaccess file.
To force WordPress to generate a new .htaccess file, go to your WordPress dashboard.
Then, navigate to Settings → Permalinks .
You do not need to change any settings.
Simply click on the “Save Changes” button and WordPress will automatically generate a new, clean .htaccess file:
That’s it! Hopefully your site will be back to normal.
Potential Fix 2: Deactivate plugins and find the faulty plugin
If there are no issues with your .htaccess file, then the next step you can try is to deactivate your plugins.
Plugin issues or conflicts often cause an internal server error. This is especially likely to happen if you see this error right after activating a new plugin.
By deactivating plugins, you can find the problematic plugin and remove it.
How to deactivate plugins if you still have access to your dashboard:
If you still have access to your WordPress dashboard, go to the plugin management area and deactivate all plugins at once using the checkboxes:
Then, reactivate them one by one, hoping to find the problematic plugin.
How to deactivate plugins if you cannot access your dashboard:
There’s a good chance that you can’t access your WordPress admin panel due to a WordPress internal server error. In this case, you’ll need to take a slightly different approach and deactivate plugins using FTP.
- Connect to your website via FTP or a file manager. You can use FileZilla.
- Navigate to the /wp-content/ folder.
- Rename the plugins folder to something like plugins_old.
Once you rename the folder, all current plugins will be deactivated.
Now try to open your WordPress dashboard, if you can access it, you should be glad that you succeeded. The problem is with a plugin.
If you go to the plugins section of WordPress it will say the error "This plugin has been deactivated due to an error; plugin file does not exist."
Don't worry...we've discovered that the problem is with one of the plugins.
To reactivate them one by one:
- Rename the plugins folder from **plugins_old to **plugins.
- Now activate each plugin one by one from your WordPress dashboard.
- After activating the plugin, browse 3-4 pages on your blog. Repeat this step until you find the plugin that is causing the internal server error.
In most cases, this will fix the internal server error issue.
Potential Fix 3: Increase Web Hosting PHP Memory Limit
Still not working? Don't worry...there are other things you can try.
Another potential problem is that your WordPress site has reached its PHP memory limit. By default, WordPress will try to allocate 40MB of memory for a single-site installation ( as long as your host allows it ).
But if you get stuck, you can increase this limit manually ( again, as long as your host allows it ).
To do this, you need to edit the wp-config.php file. You can access it via FTP or through cPanel's File Manager:
Add the following line of code before the /* That's all, stop editing! Happy blogging. / message :
define( 'WP_MEMORY_LIMIT', '64M' );
Remember - this will only help if your host has not set a PHP limit below 64M.
Therefore, if you don’t notice changes after editing your wp-config.php file, I recommend contacting your host to review your current PHP limitations.
Potential Fix 4: Re-upload WordPress core files
If your site still doesn’t work properly, you can try uploading a clean copy of the core WordPress files.
For this solution, I recommend using an FTP program instead of a file manager.
Note: Before performing this step, make sure you have a complete backup of WordPress. You can learn about WordPress backups here .
To do this, visit WordPress.org and download the latest version of WordPress:
Once the download is complete, unzip the ZIP file and delete it:
- The entire wp-content folder.
- wp-config-sample.php file.
Then, upload all remaining files to your WordPress site via FTP. Your FTP program will display a warning about duplicate files. When this happens, be sure to select the " Overwrite Duplicate Files" option.
Fixing the "Internal Server Error" message
At this point, hopefully, one of these solutions helped you fix the Internal Server Error message on your WordPress site.
If not, I recommend contacting your hosting support team and asking them to help you look through your error logs to pinpoint the problem. If they can’t help, you may need to hire a real WordPress developer to diagnose the problem.
Alternatively, you can always leave a comment and we can try to fix the problem together!
Let me know if you have faced this issue and what steps you took to overcome it…
Disclosure: Some of the links in this article contain affiliate links, which means we may earn a commission if you click through to visit us, at no extra cost to you. See how SidelinePlay is funded, why it’s important, and how you can support us.
Was this helpful?