Seven Most Common WordPress Errors And How To Fix Them

September 27, 2020
1 Star2 Stars3 Stars4 Stars5 Stars

WordPress is the easiest and most popular way to build your website or blog. It is an open-source website creation platform that uses a MySQL database and is written in PHP (Hypertext Preprocessor). WordPress was initially created as a blog-publishing system. But gradually it has emerged to help various types of traditional mailing lists and forums, membership sites, media galleries, online stores and learning management systems (LMS). It is used by more than 60 million websites, including 33.6% of the top 10 million websites. It is perhaps the most popular content management system (CMS) solution in use.

Designed with versatility and usability in mind, WordPress is an excellent solution for both large and small websites. And WordPress errors are no joke. While some may cause only minor difficulties, others can result in critical problems. But don’t worry! The greater point is that the WordPress error you see on your site has been reported and fixed by someone before you. In this article, we will include the seven most common WordPress errors, along with explaining to you how to fix them:

  1. 404 Error

The 404 Error is familiar to most internet users. It signals that the server was incapable of finding the requested page. This error is usually connected with changed URLs and broken links. .htaccess file is the reason behind the broken links. This file handles the site’s hyperlink structure, and it redirects your URL incorrectly.

The first step to solve it is that you should regenerate a new .htaccess file. However, if regenerating the .htaccess file doesn’t solve the error, you may require to re-upload .htaccess . The simplest process is to create a new file, give the name .htaccess and paste the following default code:

# BEGIN WordPress

<IfModule mod_rewrite.c>

RewriteEngine On

RewriteBase /

RewriteRule ^index.php$ – [L]

RewriteCond %{REQUEST_FILENAME} !-f

RewriteCond %{REQUEST_FILENAME} !-d

RewriteRule . /index.php [L]

</IfModule>

# END WordPress

After the default code, upload the file to your site’s source folder. In most states, this should fix the 404 error.

2 . 403 Forbidden

WordPress is a popular site; and there are several measures to keep the site safe, including different levels of ‘permissions’. The features help you to prevent people from gaining access to your site without permissions. But it may sometimes cause difficulties as well if the permissions are not correctly set. 403 Forbidden error is one such obstacle. The 403 Forbidden error code is displayed when the server does not permit access to a specific page. This issue occurs due to the Content Delivery Network (CDN) or as a result of a problem with a plugin or hotlink protection. There are several outlines when this error occurs. For example:

  • while installing WordPress
  • while visiting another page on the WordPress site.
  • ‘Access Denied’ is detected instead of full 403 Forbidden status.

The most obvious reason for the 403 Forbidden error in WordPress is due to poorly configured security plugins.

In order to fix this issue we need to generate a new .htaccess file or reset the file permissions.  Disabling the WordPress plugins is another process to follow in order to solve the error.

3 . Incorrect File Permission

We sometimes see the site denying access to certain areas of the site, same as “Sorry, you are not allowed to access this page” error. This incorrect file permissions can block you from:

  • installing or Updating themes and plugins
  • Updating or publishing post and pages
  • Image uploading.

Similarly, if the permissions of your file aren’t too strong, this may leave your website unprotected, and hackers can reach access to your files. They can steal your data, delete content or attach other malicious code.

Therefore, if you suspect that you’re hacked, or are running into one of the above issues, you may need to verify your file permissions via Secure File Transfer Protocol. The default numeric values for WordPress are 644 for files and 755 for folders.

  1. Error 521

Cloudflare error 521 is used as a CDN for protection against DDoS. If a 521 error is detected on your website, it indicates Cloudflare is not able to connect to your server; it might be blocked, or the internet might be slow.

For this, you have to check if the server is up. You also need to verify if its firewall has all of the Cloudflare’s IP ranges whitelist which in turn will help you to understand the root cause of the problem. Here is a list of some definite technical steps :

  • The source server is not configured to support Cloudflare’s IP addresses to access port 443, if Cloudflare’s HTTPS is just initiated
  • Should use Flexible SSL instead of Full SSL at Cloudflare
  • Use a recent version of mod_security
  • Disable and unload the mod_antiloris or mod_reqtimeout Apache modules

5 . Not Allowed to Access This Page

If the permissions settings of your site are incorrect, they could heedlessly block you from accessing your site. This can appear in an error that reads: “Sorry, you are not allowed to access this page”. This error message has many possible solutions.

The following steps can be taken to fix the issues:

  • Reset file permissions via Secure File Transfer Protocol (SFTP).
  • Make sure to check if your account is assigned to the correct user role through phpMyAdmin.
  • Ensure your database has a valid prefix.
  • Troubleshooting for plugin and theme conflicts.
  • You can also reset WordPress or restore a backup of your site.

6 . Memory limit error

The hosting provider allots a particular amount of server memory to your site. If the memory of the server finally gets over, you might run into difficulties installing a theme or a new plugin or uploading media files to your site. Instead of adding your new resource successfully, you’ll see a message that reads: “fatal error: memory size has been exhausted”.

If this appears, you can try increasing your PHP memory limit by updating your wp-config.php file. You can also check the total disk space you’re using and upgrade to a new hosting plan that extends more space for your expanding WordPress site.

7 . Syntax Error

The Syntax error transpires when we try to add code snippets into WordPress and put an incorrect syntax or if we miss something accidentally. This results in a PHP parse error, and then we might notice:

Parse error- syntax error, unexpected $end in /public_html/site1/wp-content/themes/my-theme/functions.php on line 277

The error message indicates the unexpected error obtained in the code. To repair this issue, you need to correct the syntax. Most of the time it is a missing bracket or some random character in the code.

So, this was all about the 7 most common WP errors. Hope this post helps you to ease out your problems with WordPress.

Leave a Reply

Your email address will not be published. Required fields are marked *