WordPress errors can really be annoying. While WordPress is the most popular and one of the easiest CMS to use, some common WordPress errors can make you get worried and shrink to the lowest of yourself.
Fortunately, these common errors in WordPress are likely experienced and reported by someone else before you. It is therefore very easy for you to find and resolve the error because someone else has already dealt with it.
Table of Contents
- Before Fixing Any WordPress Error
- Emergency Recovery Script
- 1. How to Fix Error Establishing Database Connection
- 2. How to Fix White Screen of Death in WordPress
- 3. How to Fix 500 Internal Server Error
- 4. How to Fix Memory Exhausted Error
- 5. How to Fix Maintenance Error in WordPress
- 6. How to Fix Image Upload Issue in WordPress
- 7. How to Fix WordPress Not Sending Email Issue
- 8. How to Fix 403 Forbidden Error
- 9. How to Fix Too Many Redirects Issue in WordPress
- 10. How to Fix This Site Ahead Contains Harmful Programs Error
- 11. How to Fix Mixed Content Error
- Common WordPress Errors and Issues: Conclusion
Here, we have a series of tutorials about how to fix common WordPress errors. In this article, we are going to cover 11 most common WordPress errors and how to properly fix them.
Before Fixing Any WordPress Error
It is important and essential to ensure that you have created a backup of your website before trying to fix common WordPress errors. You can use common WordPress backup plugins such as UpdraftPlus or perform manual backups.
Emergency Recovery Script
The ultimate tool for solving all your WordPress mistakes and errors is the great Emergency Recovery Script.
No matter which kind of error you encounter, whether you can’t remember your password or the admin panel is nonexistent, or maybe you messed up badly and want your website back, ERS has your back. It has a plethora of tools that will provide you with the much-needed help and allow you to get your website back in one piece.
Now you may be wondering what ERS even is? What makes it so good? Let’s explain. ERS is a single-file PHP script that works independently of WordPress, meaning you can access the script even if your WordPress isn’t working. It analyzes your WP independently and provides you with different tools.
Next, you can be sure that ERS is completely safe to use and will not jeopardize your whole site and its integrations. To access it, you will need a secret and unique URL that is your only, and the password for it. In addition, you have control over all of the features and tools, so nothing is automatic and done without your knowledge. Plus, you can install it whenever, whether you want it for precaution at all times, or just for specific situations.
Now, lets’s go over some of its tools. First, we can mention WordPress Information and Sever Information, which give you more insight into your installation and the server. Knowing that information, you get a great start on fixing the site. Then, we have Core Files, which check every file you have and compares it to the master copy. If the files don’t match, the tool will report them and allow you to replace them. Also, Core Files scans for faulty or wrong files and deletes them.
The next tool from ERS’s list is Snapshots, which is also WP Reset‘s feature and a life-saver! When you take a snapshot, you can easily revert your website to that state. Now, ERS lists all of the snapshots and allows you to upload the snapshot if it was stored remotely.
Other ERS’s tools include easily enabling/disabling themes and plugins, changing user roles, creating a new administrator account, deleting or resetting .htaccess, and disabling WordPress Maintenance Mode.
1. How to Fix Error Establishing Database Connection
The error “Error Establishing Database Connection” is one of the most scaring WordPress errors that you can encounter. This error means that your site is not able to have any communication with the WordPress database.
This means that your entire website is down and you should act fast as possible. This is because when your website goes down, it affects your traffic, analytics and even revenues.
Causes of Error Establishing Database Connection
You should not worry because we have provided you the most probable causes of this error and how you can fix it. When you know the cause of this error, you can easily get the solution and fix your site to get back up in no time.
When you incorrectly change your database credentials, you are sure to get this error. Other causes of this error include corrupted database, corrupted files, and issues with your server.
Because all or most of the information on your WordPress website is stored in the database. This information includes such things as page and post data, plugin settings, metadata, login information and much more. All these are stored on the MySQL database.
Some of the information that is not stored here includes media content, core plugin and theme files such as index.php, etc.
When someone clicks on your site, the information is retrieved from the database and presented to the visitor on the browser. If anything breaks, there is no way for the visitor to surf the site.
To make it even worse, you will lose access to your WordPress dashboard. This is the cause of this error.
Solutions for Error Establishing Database Connection
There are several ways through which you can fix error establishing database connection. These include the following;
- Use correct login credentials.
- Perform repairs in case you have a corrupted database and corrupted files.
- Consult your database server in case of server issues.
- Restore your site to the last backup when the site was okay.
2. How to Fix White Screen of Death in WordPress
The white screen of death is another most common WordPress error that you can encounter.
It is quite puzzling because all that you can see on your website is a white screen with nothing else on it. No error notification or anything.
To make it even worse, this error locks you out of your site such that you cannot access your dashboard.
For instance, you can encounter the white screen of death on your dashboard; you encounter a blank admin area while everything else is fine. Shockingly, you can get the white screen of death on a specific page or post while all other areas are just fine.
Causes of WordPress White Screen of Death
When you encounter the white screen of death, in most cases, it means just one thing; a script on your site has done in its memory limit.
In this way, the script that is unresponsive times out or gets killed by your hosting server. Because of this, there is no error message that will get generated; what you encounter is a blank white screen.
Other causes of white screen of death include defectively coded plugin or theme on your site, or an issue on the server-side.
Supposing you have other sites on the same hosting account and they are also suffering from the same error? This will clearly tell you that the issue lies with the server.
If only one site or part of the same site is affected, then the problem is with that particular site.
Solutions for White Screen of Death
There are several ways through which you can fix the white screen of death error in WordPress. Depending on the particular cause of the error, you can fix it by using the following methods;
- If the error is being caused by a plugin or theme installed on your site, disable the plugin or theme. Remember that you may not see the white screen of death starting with WordPress 5.2. You may get “The site is experiencing technical difficulties” error instead.
- Increase PHP memory for WordPress such that the scripts are able to finish what they are supposed to deliver.
- If the issue is with the plugins, disable all of them and activate them back one by one. You can do this via the dashboard or your cPanel. If you cannot access your dashboard, you can rename the plugins folder on the cPanel. This will deactivate all the plugins on your site automatically.
- Uninstall the theme and use a default one. If this works for you, check your php file. If there are any extra spaces at the bottom, remove them.
- Enable the WordPress debug mode in order to catch the issues that may be bringing this error.
- Clear your cache.
- If this white screen is happening on a post or page, increase the PHP capability of processing.
3. How to Fix 500 Internal Server Error
500 internal server errors is another most common WordPress error that you can encounter.
When you visit a site, the browser sends a request to the website server. Once the server receives the request, it processes and sends back to the browser the resources requested.
These resources include such things as PHP, CSS, and HTML among others. The server also responds with the HTTP header and status code. The status code can be 200 meaning that everything is fine or 500 which means that something went wrong.
There are several 500 status code errors like 501, 502… all meaning different things. But for this case, 500 internal server errors indicate that something unexpected prevented the server from processing the request.
Different browsers, servers, and operating systems present this error in different formats.
However, most of them will include 500 in their presentations. If this error persists and your site is down for an extended period, this can affect your SEO ranking. What does this mean? Loss of revenue and traffic!
Causes of 500 Internal Server Errors
500 internal server errors in WordPress can be caused by a myriad of issues. If you are experiencing this error, it is most likely caused by one or more of these issues;
- Corrupted files, database or wrong database login credentials.
- Database server issues.
- Your browser cache.
- PHP memory limits.
- Incompatible themes and plugins.
- Script errors.
Solutions for 500 Internal Server Error
It is good to note that the solution to this error depends on the origin of the error. This means that the error can be from the server or client-side. Some of the most common fixes for 500 internal server errors include the following;
- Reload/refresh the page.
- Clear your cache
- Use the server logs to determine the cause of the error and act.
- Ensure your database login credentials are right.
- Examine your plugins and themes. You should troubleshoot by deactivating them and activating them one by one. For the theme, use a default theme to check.
4. How to Fix Memory Exhausted Error
Memory Exhausted Error is a common WordPress issue that requires attention immediately. This error means that you need to increase your PHP limit for your site to work well.
It is a common practice for most web hosting service providers to set a limit on the memory used during the processing and execution of PHP script on the server.
In an event that the PHP script tries to go beyond this limit, the script halts and you get “Memory Exhausted Error”.
Causes of Memory Exhausted Error
There is only one cause of Memory Exhausted Error in WordPress. It is common knowledge that WordPress is written in PHP and any attempt by the scripts to consume more than the PHP set limit, the error occurs.
Solutions for Memory Exhausted Error
This Memory Exhausted Error has only one simple solution- increasing the PHP memory limit. This is done through several methods;
- Contact your hosting provider and request an increase to the memory limit.
- Manually increase the PHP memory limit via cPanel.
5. How to Fix Maintenance Error in WordPress
When you are performing admin tasks on your WordPress dashboard, the site will appear to anyone visiting it as under maintenance.
This means that the site will present a screen to the visitor informing them that the site is undergoing maintenance and therefore inaccessible.
For this reason, your website is not visible to the public. This is good when you are surely performing maintenance tasks on your site.
However, sometimes something goes wrong and your site remains under maintenance even when you are not doing any maintenance job. This results to Maintenance Error. Now, this is not good. Especially if this error prevents you from accessing the dashboard!
Causes of Maintenance Error in WordPress
When you are perming maintenance tasks on your admin area, the website needs to properly accept the changes and “move on”. However, this is sometimes not as flawless as it appears. Therefore, some of the causes of Maintenance Error include the following;
- Failure for the site updates to take effect successfully.
- Unexpected elements such as power failure in between site updates.
- Theme and plugin update issues.
- Low server memory.
- Slow server setup.
Solutions for Maintenance Error
There are several methods through which you can fix the Maintenance Error. Some of the most common fixes for Maintenance Error include the following;
- Delete the .maintenance file from your website using cPanel.
- Use a plugin to customize yours under maintenance page.
- Use code to create your own custom under the maintenance page.
- Avoid Maintenance Error by avoiding bulk updates of your site elements.
6. How to Fix Image Upload Issue in WordPress
Do you have image upload issues on your WordPress site?
Image upload issues and errors can be quite daunting for inexperienced WordPress users. This is because these errors can occur without doing something different from the normal.
This error means that you are unable to upload images on your posts and pages.
Causes of Image Upload Issues and Errors in WordPress
The cause of image upload issues and errors in WordPress is normally wrong file permissions.
You should remember that all your files are stored on your web hosting server. These files require a specific and correct directory and file permissions in order for them to work properly.
With incorrect permissions, WordPress will not be able to read or upload files on the server. This will result in upload errors. The file and directory should have correct writing and reading permissions.
In addition to getting this error, you may also realize that images have disappeared from the media library altogether.
Apart from incorrect file permissions, you can encounter this error from the server-side. For example, an upgrade by the server may cause misconfigurations and alter the file permissions.
You may, therefore, ask “what caused a change to my file permissions?” But if all other aspects of your site are working normally, it is easy to fix these errors.
Solutions for Image Upload Issues in WordPress
There is only one solution for image upload issues and errors in WordPress;
- Use cPanel to apply the correct file and directory permissions. The right file permissions for this solution should be 744. If this does not work for you, then use 755.
7. How to Fix WordPress Not Sending Email Issue
WordPress Not Sending Email Issue means that you are unable to send any mails using your WordPress platform.
This is a common occurrence and a headache for many beginners. All credible email service providers perform tests in order to minimize spam.
Among the most important tests done is to determine whether an email originates from where it purports to be coming from. In many instances, emails sent by WordPress do not pass this test. This results to this error.
Experienced WordPress users will tell you that it is not advisable to use WordPress to send an email newsletter. Instead, you should use the Simple Mail Transfer Protocol (SMTP).
Causes of WordPress Not Sending Email Issue
The main cause of this issue is when your web hosting server is not configured to properly send emails. In order to send emails, your server must be configured to use PHP mail() function.
However, as mentioned above, even if your server allows for sending emails, most email service providers will still prevent these emails from being sent. Even worse, the emails will not make it to the spam folders.
Solutions for WordPress Not Sending Email Issue
There are several solutions for WordPress Not Sending Email Issue. However, the most common fixes include the following;
- Make sure that your web hosting server is configured to use PHP mail() function.
- Use a good SMTP.
8. How to Fix 403 Forbidden Error
Are you getting the dreaded 403 Forbidden Error? 403 Forbidden Errors mean that you do not have the right permissions to view the requested file or another resource.
All executable scripts must have 755 permission. When it comes to images, media and text files, the permission should be either 755 or 644.
Causes of 403 Forbidden Error
There are several causes of this error. The major cause of this 403 Forbidden Error is trying to access and view dot (hidden) files from the browser.
For example, any attempt to view .htaccess will trigger the error. Another possibility for this error is IP deny rules. Faulty and incompatible plugins and themes may also result into this error.
Solutions for 403 Forbidden Error
There are three main methods through which you can fix 403 Forbidden Error. These are;
- Check and rename or reset your .htaccess
- Reset file, folder and directory permissions.
- Disable all your WordPress plugins then activate them one by one. This is because some faulty plugin may be causing all these nuisances.
9. How to Fix Too Many Redirects Issue in WordPress
If your site keeps redirecting to different addresses in a manner that will never complete, you will encounter the Too Many Redirects Issue. This means that your site has too many competing redirects.
In some instance, the site may be redirecting to HTTPS while still trying to load HTTP. In other ways, your site may be eternally oscillating between www and non-www versions of your site.
So your browser will not let you wait for eternity; it will present the error when the redirects get to ten or so.
Causes of Too Many Redirects Issue
Too Many Redirects Issue is usually caused by several things. These include the following;
- Having the wrong URL in your URL settings. This includes the use of SSL and www on your URL and omitting them on your URL settings.
- Using the wrong 301 redirects.
- Website cookies.
- Server-side issues.
Solutions for Too Many Redirects Issue
In order to fix Too Many Redirects Issue, there are several steps that you should take. These include the following;
- Delete cookies.
- Clear your browser, proxy and server cache.
- If you are using third party services like Cloudflare, check them out to ensure that there are no conflicts when it comes to redirection.
- Disable or deactivate any incompatible plugins.
- Rename your .htaccess file or use a backup version of it and delete the current one.
10. How to Fix This Site Ahead Contains Harmful Programs Error
If you encounter a warning that “This site ahead contains harmful programs” you should not visit that site because you risk getting malware on your device.
What if this warning refers to your WordPress site? This means that your website has been hacked and a risk to visitors and other websites.
Causes of This Site Ahead Contains Harmful Programs
The main cause of this error and warning is hacking. When your site is hacked and believed to be spreading malware or Trojan, search engines like Google will mark your site as such and warn users to visit your site at their own peril. If your website has a suspicious and dangerous malware or Trojan code, you are certainly sure to be marked as such.
Another likely reason for “This site ahead contains harmful programs” warning is if you are running adverts on your site using low-quality advertising sources. These ad networks may be serving adverts directly linking to sites that are spreading malicious and viral codes.
Solutions for This Site Ahead Contains Harmful Programs
What do you do if your site is hacked? What do you do to remove the malicious codes in your website? There are no shortcuts when it comes to cleaning your website. Some of the steps you may take would include the following;
- Hire a WordPress Security expert to clean your site.
- Use the best WordPress security and malware removal tools to clean and secure your website.
- When you are sure that your website is clean, ask Google to remove “This site ahead contains harmful programs” warning through the Google webmaster tool.
11. How to Fix Mixed Content Error
If you are not using SSL on your site, then you are missing out on quite a number of SEO benefits. If you are using SSL on your site but not applied to the right settings, then this is even worse.
Improperly setup SSL means that while your website is using SSL, some content in your website is being served from no secure URLs. This is what is called Mixed Content Error.
Causes of Mixed Content Error
The main cause of Mixed Content Error is improperly configured SSL setup. This means that some of the content in your is not served from a secure URL. This may not affect the functionality of your website but will negatively affect your SEO ranking and scores.
Solutions for Mixed Content Error
There is only one solution for Mixed Content Error;
- Correct SSL setup.
- Replace every instance of HTTP to HTTPS with the Better search plugin, here is the complete guide to moving WordPress site to HTTPS.
Common WordPress Errors and Issues: Conclusion
Common WordPress errors and issues can be a severe headache to WordPress users especially those who are just starting out.
Fortunately, there is no error or issue that you can encounter that does not have a solution. It is always likely that someone before you encountered and solved this.
In this article, we have shown you the most common errors in WordPress and how to fix them. Keep checking our resources for in-depth tackling of the solutions for the specific errors and issues.
Learn more about WordPress development at ThemeLocation which offers competitively priced packages for premium development services.