WordPress powers about 40% of all sites on the web, making it one of the most popular site-building applications. Here’s how to troubleshoot some of the common errors that might affect your WordPress site.
Error establishing a database connection
WordPress uses a database to store important data, like information about the site’s users, posts, pages, and comments, for example. If your site can’t communicate with the database, you’ll see the Error establishing a database connection notification instead of the site’s content.
This issue can appear after you move your WordPress site or, for any other reason, change your WordPress database location, username, or password. Here’s how to fix this error and get your site back online by updating the database connection strings.
(Back to top)
Internal server error (error 500)
Another issue that can affect your WordPress site is an internal server error (ISE), also known as Error 500. It’s a generic server error that lets you know that the server cannot load the site.
Since it doesn’t include specific information, resolving it is a matter of trial and error, which can be time-consuming. Follow these troubleshooting steps to fix the ISE.
(Back to top)
The site is experiencing a critical error
When, instead of the site’s content, you see a notification that your site is experiencing a critical error, there may be an incompatibility between plugins, themes, or WordPress versions that prevents the site from loading correctly.
In that case, you should receive an autogenerated email that lets you know about the error, with a sign-in link to your site in recovery mode. You can access your WordPress dashboard through that link even if it’s affected by the error. This is the first step in fixing the critical error.
If you can’t find the email, treat the critical error like the “white screen of death” error and follow the steps from the next paragraph.
(Back to top)
The site displays a white page
The white screen of death (WSOD) error can be frustrating because you see only a white screen when you visit your site, and there are no error notifications to point you in the right direction. The issue is usually caused by a faulty plugin or theme or a conflict between them. Therefore, you should focus on determining what caused the error so that you can disable or fix the faulty plugin or theme.
(Back to top)
Briefly unavailable for scheduled maintenance
If you notice that your site displays the Briefly unavailable for scheduled maintenance notification for a prolonged period after you run updates on your WordPress site, follow the steps from this article to remove the file which is causing the issue.
(Back to top)
404 errors on posts or pages
Note: The following solution will fix only 404 errors that appear sitewide. If you see the error only when visiting certain pages, it can be caused by a typo in the permalink, or if the page got deleted in the meantime
If your site displays the home page correctly, but you see the 404 error when visiting all other posts and pages on your site, this usually means that the .htaccess file is missing. You should resave your permalinks to regenerate the .htaccess file.
(Back to top)
Mixed content error
If you recently installed an SSL on your site and some images are not loading properly, you should check if you have a mixed content error on your site. These errors are typically caused by assets that have http:// rather than https:// in their URL.
Here’s how to inspect your site with developer tools in different browsers to verify the issue. You’re looking for mixed content error warnings in the console log.
- Chrome
To look for errors in Google Chrome, visit your site in Google Chrome, select and hold (or right-click) somewhere on your page, and then select Inspect. In the top menu, select Console and look for red warnings about the mixed content error.
To fix the error, you can use a plugin or edit the .htaccess/web.config file. After that, visit your site in private browsing mode to see if the images are loading correctly.
If you still see the mixed content error, download your active theme to your local computer and search those files for your site’s URL. You should update all URL entries from http:// to https://, such as changing http://solveforce.com to https://solveforce.com (use your actual domain instead solveforce.com) and reupload the files.
- Firefox
To use developer tools in Firefox, visit your site in Firefox and select and hold (or right-click) somewhere on your page, and then select Inspect (Q). In the top menu, select Console and look for red warnings about the mixed content error.
To fix the error, you canΒ use a plugin or edit the .htaccess/web.config file. After that, visit your site inΒ private browsing modeΒ to see if the images are loading correctly.
If you still see the mixed content error, download your active theme to your local computer and search those files for your site’s URL. You should update all URL entries from http:// to https://, such as changing http://solveforce.com to https://solveforce.com (use your actual domain instead solveforce.com) and reupload the files.
- Safari
In Safari, you should enable developer tools first. Visit your site in Safari, and from a top menu in your browser, select Develop and then select Show Web Inspector. Select Console and look for red warnings about the mixed content error.
To fix the error, you can use a plugin or edit the .htaccess/web.config file. After that, visit your site in private browsing mode to see if the images are loading correctly.
If you still see the mixed content error, download your active theme to your local computer and search those files for your site’s URL. You should update all URL entries from http:// to https://, such as changing http://solveforce.com to https://solveforce.com (use your actual domain instead solveforce.com) and reupload the files.
(Back to top)
More info
- If you want to find out more, check out the extensive list of errors that can affect your WordPress site.