Home » WordPress Tutorials » Errors » WordPress 404 Not Found

WordPress 404 Not Found

Errors

WordPress is a commonly used CMS and can be installed both on our Free and Premium hosting plans. The “404 Page not Found” is also a common error every website owner would run across. Luckily, fixing the error is a simple task and could be done by everyone. In this article, we will walk you through the process to fix the 404 error for WordPress.

 

What is the WordPress 404 Error?

The 404 error is one of the many HTTP status codes which you might run into on the internet. The error page would appear when you try to access a page and your browser can’t find it. The 404 error message could be different depending on the browser you are using. For example, Firefox would return a “404 Not Found” error while Chrome would return “404. That’s an error.”.

wordpress-404-error

 

There are different things that could cause a 404 error in WordPress such as:

  • Incorrectly entered URL
  • Deleted post or page
  • Caching problem
  • DNS issue
  • WordPress compatibility issue

 

How to Fix the 404 Error?

As long as the “404 Not Found” error is not caused by an incorrectly entered URL or cache, there are a few things that you can do to fix the error.

 

Reset WordPress Permalinks

WordPress permalinks are used to structure the URL of your website. WordPress provides you with several options from which you can choose from the WordPress admin panel:

You can reset the Permalinks via the WordPress dashboard or via FTP. If you have access to the WordPress dashboard simply navigate to the Settings > Permalinks page. From there change the Permalinks to Plain, which will be a temporary change and save the changes. Once you have done that you can go back and change the Permalinks to the option which you were using.

 

wordpress-permalinks

 

If you do not have access to the WordPress dashboard, start by connecting to your website directory via FTP or access the File Manager. Once you have accessed your website files you will have to find the .htaccess file and edit it. Very often the .htaccess file will look as shown on the screenshot below:

 

htaccess-filemanager

 

To fix the .htaccess file you need to add the following default code for the .htaccess:

<IfModule mod_rewrite.c>
RewriteEngine On
RewriteRule .* – [E=HTTP_AUTHORIZATION:%{HTTP:Authorization}]
RewriteBase /
RewriteRule ^index\.php$ – [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /index.php [L]
</IfModule>

 

Once you have added the code make sure to save the changes.

 

wordpress-htaccess

 

You can now reload your page and check if your WordPress is returning the “404 Not Found” error. If you see the page successfully – congratulations, you have fixed the error all by yourself.

 

How to Check if the “404 Not Found” Error is Caused by a Plugin or Theme

Sometimes the plugins and themes which you use might also affect the structure of your WordPress URL. If the above methods do not resolve the 404 error, disabling your plugins and themes is the next step you can take.

There are two ways to disable your plugins depending on whether you can access your WordPress dashboard or not. We have covered this process in our article “How to uninstall a plugin in WordPress“.

The purpose of this process is to find which plugin is causing the error by disabling them one by one. You can also revert the process and disable all plugins and enable them one by one, in case multiple plugins are causing the error. Once you have identified the plugin causing the error there are a couple of this you can do:

  • You can contact the developers of the plugin so they can assist you with resolving the issue
  • You can remove the plugin and look for an alternative one

If you have gone through all plugins and none of them is causing the error, you will also have to check your current theme. Unlike the plugins, this process is done much faster since you have to check only one theme. All you need to do is change your WordPress theme to a different one. You can refer to our article “How to Change a Theme in WordPress” for more information. Now check if the 404 error still persists. If the error is fixed you will once again have to choose between contacting the developers of the theme for fixing the issue or replacing the theme.

Was this post helpful?

i

Relevant tags:

Create your WordPress website today!

Connect

Editor’s picks:

Gutenberg Tutorial: How to Move Blocks in WordPress

What you need to know: The WordPress Block Editor allows you to move blocks up and down the document structure in order to rearrange the content contained within those blocks. The most popular way of moving blocks is by dragging a block from one position and dropping...

Gutenberg Tutorial: Deleting a Block in WordPress

What you need to know: You can delete a block in WordPress by selecting it and pressing the Delete key on your keyboard. Alternatively, you can press the three-dot button in the Contextual Toolbar to access the Remove block option. Lastly, it is also possible to...

Gutenberg Tutorial: Using Block Patterns in WordPress

What you need to know: A block pattern in WordPress is a group of two or more regular WordPress blocks. These blocks come in a sensible layout that you wouldn’t need to modify in most cases. Instead, you just need to add your own content to the block pattern. You can...

Gutenberg Tutorial: Using WordPress Reusable Blocks

What you need to know: Gutenberg features reusable blocks that allow you to quickly insert the same content with one click. You can mark any block or block pattern as reusable. You can find your reusable block collection in the WordPress Block Library. Have you ever...



Create your WordPress website today!


Start now