There’s nothing more frustrating than encountering a WordPress error on your site.
As stable as WordPress is most of the time, sometimes things happen and your site, or maybe just part of your site, stops working.
Luckily, most WordPress sites experience the same types of errors, so it’s usually pretty easy to diagnose the most common WordPress errors.
To help you out, we’ve created guides to fix many of the most common WordPress errors that you’re the most likely to encounter.
Here are the specific issues that we’ll cover:
- Error Establishing A Database Connection
- WordPress White Screen Of Death
- 500 Internal Server Error
- 403 Forbidden Error
- 404 Page Error
- Connection Timed Out
Let’s fix some errors!
1. Error Establishing A Database Connection
Error Establishing A Database Connection happens when your WordPress site can’t communicate with your database server. This crashes your site because WordPress is unable to access the content and important settings that are stored in the database.
How To Fix Error Establishing A Database Connection
- Try using the WordPress database repair tool to see if your database is corrupted. This tutorial from 000webhost.com has a good explanation of how to use the database repair tool.
- Create new database user credentials in your cPanel account, assign them to your WordPress site’s database, and update your wp-config.php file. That should guarantee that your site has the right credentials.
- Speak to your host. Sometimes your host’s database server might be down, which is causing the error. Unfortunately, there’s no way to fix this by yourself – it’s up to your host.
2. WordPress White Screen Of Death
The WordPress White Screen of Death is a frustrating error that presents as either a completely white screen (in Firefox) or a generic error message (in Chrome).
It’s like the Windows Blue Screen Of Death – but for WordPress!
It can be a little hard to diagnose because it can be caused by both PHP and database errors. But here are some tips for figuring out what’s going wrong.
How To Fix WordPress White Screen Of Death
- Deactivate all of your plugins and reactivate them one by one. If you can’t access your WordPress dashboard, you can do this by renaming the wp-content/plugins folder over FTP. By reactivating them one by one, you can figure out the specific plugin that might be causing the issue.
- Change back to the default Twenty Seventeen theme. Again, if you can’t access the WordPress dashboard, you can do this via FTP by renaming the folder for your current theme.
- Increase WordPress’ memory limit. You can do this by adding this code snippet to your wp-config.php file:
- Enable the WP Debug tool and look for specific errors by adding this code snippet to your wp-config.php file:
define( 'WP_DEBUG', true );
Make sure to remove this code snippet when you’re finished!
3. 500 Internal Server Error
500 Internal Server Error, sometimes just Internal Server Error, is a catch-all message for when something goes wrong with your server. Because it’s a generic message, it’s a little bit hard to diagnose. But here are some tips:
How To Fix 500 Internal Server Error
- Generate a new .htaccess file. Connect to your site via FTP and rename your .htaccess file to something like .htaccess_old. Then, go to Settings → Permalinks in your WordPress dashboard and click the save button to force WordPress to generate a new .htaccess file.
- Deactivate all of your plugins and reactivate them one by one. Again, if you can’t access your WordPress dashboard, you can do this via FTP by renaming the plugins folder.
- Switch back to the default theme. Like plugins, you can do this via FTP if needed by renaming the folder for your active theme (wp-content/themes/your_theme)
- Increase your WordPress site’s memory limit. Again, you can do that by adding the following code snippet to your site’s wp-config.php file:
- Reupload your wp-admin and wp-includes folders. You can do this by downloading a fresh copy of WordPress from WordPress.org, uploading the relevant files, and overwriting the current files on your host. As long as you only upload the wp-admin and wp-includes folders, you won’t overwrite anything important.
4. 403 Forbidden Error
The 403 Forbidden Error happens when there’s an issue with permissions on your site’s server. It could be an issue with a plugin or the actual file configuration on your site’s server.
How To Fix 403 Forbidden Error
- Make sure your site’s files have the proper permission codes. This tutorial has a good explanation of which permission codes to use for WordPress.
- Generate a new .htaccess file. Connect to your WordPress site via FTP and rename the current .htaccess file. Then, go to Settings → Permalinks and save your changes to force WordPress to generate a new .htaccess file.
- Disable your plugins and reactivate them one by one. Again, if you can’t access your WordPress dashboard, you can do this via FTP by renaming your plugins folder. The same tutorial article linked above in this section has a good explanation on how specifically to do this.
5. 404 Page Error
The cousin of the previous error, this one is one point more annoying! It can crop up in all kinds of places, but it’s usually pretty easy to fix.
How To Fix 404 Page Error
Just go to Settings → Permalinks in your WordPress dashboard and click Save Changes.
WordPress will update the redirect code contained in your .htaccess file and that should hopefully fix the issue.
6. Connection Timed Out
This error is commonly caused by low-quality shared hosting with low memory limits. Basically, your server is overworked and doesn’t have the power to respond to all of the requests it’s getting, so it throws this error message instead.
How To Fix Connection Timed Out
- Increase your site’s memory limit. If your host allows it, giving your site a little more power can fix the issue. Add this code snippet to your site’s wp-config.php file:
define( 'WP_MEMORY_LIMIT', '64M' );
- Try deactivating all of your plugin’s and reactivating them one by one. Sometimes you might have a plugin that’s hogging your resources, which is causing the rest of your site to stall out. If you’re locked out of your WordPress dashboard, you can deactivate your plugins by renaming the plugins folder via FTP.
7. Parse Error/Syntax Error
The Parse Error, or Syntax Error, usually pops up right after you’ve added some custom code to your WordPress site. It basically means that you made a mistake with some “part” of the code. This could be something as simple as a misplaced comma, which is why this error can be a little bit frustrating!
How To Fix Parse Error/Syntax Error In WordPress
The easiest way to fix this issue is to just remove the offending code snippet that you added.
If you’re code savvy, the error message should also tell you the exact line that contains the issue. If you can figure out what’s going wrong, you can use that information to fix the issue, rather than just removing the entire code snippet.
Stop These Common WordPress Errors For Good!
There you have it! Quick and dirty guides to fix 6 of the most common WordPress errors.
If you’re still struggling with your site not working, you might want to consider turning to expert help at this point.
Another great place to get WordPress support is from the folks over at WP Buffs – click here to learn more. Here’s to healthier WordPress sites!