12 Common WordPress Errors and How to Fix Them

Posted on Dec 06, 2019
12 Common WordPress Errors and How to Fix Them

WordPress is the world’s most famous content management system (CMS) that lets you create websites without coding. There are approximately 75 million websites built with WordPress. WordPress itself based on the PHP family.

Though using WordPress is very easy still there are a lot of errors that designers face while making a website with it. I used to worry when I face them in the beginning but, you need not worry at all I have summed up 15 most common WordPress errors and how to fix them.

Some errors are on the host end and some are caused by the inexperience of designer, anyhow you should create a backup of your website before debugging.

HTTP 500 Internal Server Error 

Internal Server Error

This is the most difficult error for non-techies also sometimes occurs as “500 Internal Server Error”. This error is canny because even the server can’t figure out what the problem is and you manually have to go through the complete website to check possible errors. It usually occurs when you try to go back to your WordPress dashboard.

How to fix Internal Server Error

Internal server errors are caused by any conflicting plugin or theme. All plugins are not compatible with all themes, using the right plugin on the right theme is one solution. Secondly, it also occurs because of a corrupted .htaccess file and PHP storage limit.

To troubleshoot this first of all locate your .htaccess file and rename it, something like .htaccess_modify. You can find it in File Manager or “using FTP” of your cPanel and rename it. This file lives with other main folders like wp-content, wp-admin and wp-includes.

Now go back and try to login to your website’s dashboard if it opens, congratulations! It solves your problem. 

Also, check the permalinks in settings and SAVE them. If this does not solve your internal server problem read below how to increase the PHP memory limit.

How to Increase PHP Memory Limit

If you are facing internal server error while uploading an image or a file you need to add a php.ini file into your cPanel’s File Manager.

How to add a php.ini file in WordPress?

  1. Create an empty file in notepad and save as php.ini.
  2. Add the code memory=64MB in that file
  3. Save it again
  4. Upload to your File Manager or “using FTP” folders in cPanel

Open your website check if the error has gone, if still remains, deactivate all the plugins and start activating them one by one, keep checking the website with the activation of a plugin, this way you will figure out what plugin caused this internal server error.

Also Read: Top WordPress SEO Plugins

WordPress White Screen of Death Error

WordPress White Screen of Death Error

This is a puzzling error. It displays nothing on the screen that gives designer heart attack of the brain. How can someone get it fixed when he has no clue what the problem is? However, this article serves you with the solution to the screen of death error.

White screen error relates to server configuration and php memory limit that occurs when script exhausts the memory limit second, poorly programmed plugins and themes are also a reason. Must correspond with your hosting company regarding the issue if below mentioned tricks fail.

  • Check out all your plugins that are newly installed 
  • Clear the cache of the website
  • Increase the PHP memory limit (as described above)
  • Create a backup of the website and deactivate the theme and then install a fresh copy of that theme

Any of the above could solve your white screen error if not you can try to become a little coder and add following lines of code to your functions.php file,

define( ‘WP_DEBUG’, true);
define( ‘WP_DEBUG_LOG’, true );

If the error occurs on a page that has a long blog post increase the PHP’s text processing capability. Open the wp-config.php file and add the following code there.

ini_set(‘pcre.recursion_limit’,20000000);
ini_set(‘pcre.backtrack_limit’,10000000);

Also Read: WordPress REST: An Ultimate Guide

Error Establishing a Database Connection 

Error Establishing a Database Connection

Error Establishing a Database connection is a usual thing for technical WordPress users while it’s alarming for non-techies. This error often occurs when your website’s PHP code is unable to connect with the MySQL database. This is the guide to fix Establishing a Database Connection error.

First of all, understand why this error occurs, it mostly comes because of some issue in your server. If the server is not fully functional at some time, it will throw this error. To troubleshooting first, check if the error is happening at your back-end www.mywebsite.com/wp-admin too. If the errors are different, then you have to repair your database, login to cPanel and go to the database and add

define(‘WP_ALLOW_REPAIR’, true)

to the wp-config.php file. In case the error is the same on both front and back end, follow the following tricks.

Rechecking wp-config.php file

Wp-config.php is the core file in the WordPress installation. It stores and establishes a connection with the website’s MySQL database. And if any changes are made to the root name or password, then it must match them with ones written in the wp-config.php file and edit them. This file has the database connectivity code in the following form.

define(‘DB_NAME’, ‘database-name’);
define(‘DB_USER’, ‘database-username’);
define(‘DB_PASSWORD’, ‘database-password’);
define(‘DB_HOST’, ‘localhost’);

In some cases ‘localhost’ after DB_HOST needs to change with your host IP and it does a great job in solving the merry error.

Contact Website Hosting Providers 

There’s a possibility that you are on short of hosting bandwidth so getting the database establishing error. When you are getting loads of traffic shared hosting is not enough, you need to contact the hosting providers and ask them to resolve the issue, you might need to purchase a better hosting with higher offerings.

Connection Timed Out Error 

Connection Timed Out Error

This error resembles the upper mentioned error that shows up when your hosting plan runs out of its capability. A big number of traffic and loads of data be published on your website are the causes of this error. The best fix is to upgrade your shared hosting plan to attain a higher bandwidth.

Another reason for connection timed out error is a poorly managed website. Every website has a limited number of resources granted by the server, so keep on optimizing your website, purge the cache especially the pages that have more data published.

Also Read: Gutenberg Editor for WordPress

Sidebar Appears Below the Main Content 

This layout based front-end error is very disturbing that turns the website into a dirty layout made by some 10 years old. 

This error shows up after editing the theme, making changes in HTML and CSS of the theme can cause this error, revert the changes to their default and check the website, hopefully, the sidebar issue would be resolved.

You need to know HTML and CSS properly to troubleshoot the error. Check for the HTML <div> </div> tags, perhaps some div is not closed. Also, check the CSS margins and make them appropriate.
W3C Markup Validation is a service that solves such HTML errors, pass your affected web page through it for quicker recovery.

Forgot WordPress Login Password 

Forgot WordPress Login Password

You forgot your WordPress websites login password and are unable to login to the site and access the dashboard or the admin panel. 

In such a case first thing, you should try is clicking on Forgot Password on the bottom of the login window. You will log in with the registered Email address, they will send you an email on that address with password recovery link. This gets the job done in most of the cases, however, you are unable to access the registered email account, do not panic here’s another solution.

Changing WordPress Password from Hosting Account

Login to your hosting account, from the admin panel, click on Domain under it you will see an option MySQL (Restore Database, phpMyAdmin), click on it. In the next window, you will be able to change the password or even the username. 

Congratulations! You can now access your website.

Also Read: How to Secure WordPress Website?

WordPress Is Stuck In Maintenance Mode 

Usually, WordPress updates as quickly and smoothly that you can not even notice it but, if you the WordPress update failed it will remain stuck and you can not log into your website.

Interestingly, this is an easy error that can be fixed quickly. You just have to connect via SFTP again and delete the file named ‘.maintenance’ which would be available in the root folder of your website.
Just get to SFTP file in cPanel, find the root folder, there you will witness a ‘.maintenance’ file, delete it and your website will be back live, up and working. This file stuck the website in maintenance mode, get rid of it and update the WordPress again.

Error in Scheduled Posts

The capacity to schedule your posts beforehand is a very valuable facility available in WordPress’ increasingly valuable facility. You can arrange posts ahead of time, disregard the site, and have content consequently distributed at the moments you fixed.

Still, occasionally this framework comes up short, and you can see an error with a schedule missed note near to a blog post.

Without being extra specialized, this issue is because of something people refer to as ‘cron jobs,’ which are actually automated tasks that WordPress undertakes so as to automate some procedures. In the event that the suitable cron jobs are not able to execute the planned activity, it will neglect to distribute and the post can stay without being published until a manual intervention happens.

The most ideal approach to dodge this bug is to utilize any of the plugins which can serve a purpose, for eg – the  Schedule Post Trigger.

Also Read: Elementor vs Divi vs Visual Composer

WordPress Keeps Logging Out Error

This also occurs your WordPress Website starts logging out repeatedly. The common attempts at a solution a layman makes are deleting the cache, deactivating the plugins or backing up the website from the backup folder. We will let you know these tricks do not work in this case, yes you need to learn the following steps to get rid of it.

First, Learn how WordPress Login works

WordPress uses cookies and starts a session when someone logs in,

In the above picture, notice that the WordPress Address (URL)  and Site Address URL are different input. This causes an error, these two must be identical with the same link structure. Put complete URL as it is and this is your first trick to solve WordPress Logging Out problem.

Second, the ultimate solution is again reaching out to your wp-config.php file, editing it with an exact URL in front of WP-HOME & WP_SITEURL.

Maximum Execution Time (of 30 seconds) Exceeded in WordPress

While attempting to upgrade a WordPress theme or plugin, you may come across ‘Fatal error: Maximum execution time exceeded’ displayed on your computer screen.

Normally this issue happens when code in WordPress (PHP) sets aside a long effort to run because then it will reach the max time limit of confinement set by the hosting server of your WordPress website. As far as possible it is significant in light of the fact that it averts the unnecessary server resource usage.

As you know, WordPress is basically coded in the leading programming language – PHP. To shield web servers from maltreatment,  a period point of confinement is set to what extent a PHP content can be run. The genuine time limit fluctuates depending upon hosting providers, nonetheless, the vast majority of the occasions the most extreme execution time set for a decent PHP script to run is between 30 – 60 seconds since that is generally a fair enough time required for the same.

whenever, at any point, a script arrives at the set time limit for maximum execution, it will show an error – termed as a fatal error or in simple terms, maximum execution time exceeded error.

Anyhow the ‘fatal error,’ is considered as the most widely recognized WordPress bug, that can easily be resolved.

This error will be shown to visitors whenever it occurs. Simply go to ‘.htaccess’ file explore the code and find php_value max_execution_time 300, change it to 600.

Also Read: Speed up WordPress Website

404 Error

The world’s most famous web error 404 Error, it shows up because of broken links on the website. Check your website completely for any broken links. Broken links are wrong URLs that don’t direct to any page but you have assigned it a page or category. There are many online platforms available where you should put your website address and submit it will show all broken links on your website.

Upload Media Error in WordPress

This is not an error rather you need to familiarise yourself with how WordPress manages media. WordPress only allows us to upload media up to 60 MB. Many newcomers try to upload heavy videos directly on their sites that are not possible, so, WordPress results in an exception on screen. The proper way to upload a heavy sized media on WordPress is to upload them to third-party video sites like YouTube and embedding the code on the website page.

Acowebs leverage the power of React in our WordPress and WooCommerce plugins so as to attain a top-notch performance. All our plugins are designed for giving equally seamless performance experience to these. Our plugins, WooCommerce dynamic pricing which is for applying bulk discounts quickly and WooCommerce checkout field editor which helps the website admins to customize the checkout form fields and WooCommerce product options which is basically to help the website admins to add extra product options or custom fields in the WooCommerce product detail page (The free version of this plugin WooCommerce product addons is available in WordPress plugin directory).

WRITTEN BY
Jamsheer K

Jamsheer K, is the Tech Lead at Acowebs and it's parent company Acodez. He mostly writes about Wordpress, WooCommerce and other programming languages and his writing normally comes from rich and hands-on experience in these technologies.