How To Resolve 404 Error In WordPress Site

Source copied from codeastrology.com for original link  click here

There are some common issues that the beginner face in WordPress. “404 Error” is one of them. But, don’t be scared. Like every issue and bug, this problem is also easy  to resolve.

Why 404 Error happened?

There are many reasons that’s why “404 error” shows  in your site. Like- May be you typed a url that doesn’t existed or changed or maybe your Permalink has been changed.

Now let’s see how to solve the issue.

Solution 1: Fix 404 Error by changing Permalink

Go to your WordPress Dashboard and click on Settings->Permalinks. From the Common Settings select Post Name.

Click on “Save Changes” Button.

This will update your permalink settings which works for most of the 404 error. In case this doesn’t works, you can follow the second method.

Solution 2: Update .htaccess file

If first solution doesn’t work, try to update your .htaccess file. Login to your CPanel and connect to your WordPress root directory. Where you will find a file named .hcaccess. Download this file.

Check if there has the following lines of code. Add the code if not exist.

# BEGIN WordPress

RewriteEngine On
RewriteBase /
RewriteRule ^index\.php$ - [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /index.php [L]

# END WordPress

Leave a Reply

WhatsApp WhatsApp us