What is 404 not found?

404 not found error indicates, whatever is requested that is not available to show or not found. In wordpress 404 not found error indicates page or post which requested not found. This problem will come when the URL or the permalink has changed. there will be 2 reason for this issue,

  1. URL or the permalink has changed. or wrong url.
  2. Requested page or post not found.
How to fix the 404 issue in wordpress pages?

Mostly this issue will come after making website live.

1. Save Permalinks

The solution to 404 error in WordPress is simply saving your permalinks. By doing this will update your .htaccess file with the correct configurations for your WordPress website.

To do this, follow the bellow steps;

  • Login to your admin panel. click settings ->permalinks
  • step1
  • check and confirm whether the permalink is clicked in post name. if it is already clicked, scroll down to the page and click save changes.
  • step 2
  • Now refresh the page in front end. it will work.
2. Reset permalinks

if the first method is not working, you can try this method. by editing .htaccess file. just copy and paste or replace the below code in your htaccess file.

# 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

Now refresh page and check.

3. Reset permalinks if your site is in a subdomain

if its a main domain the htaccess file code will vary. If your domain is a subdomain, paste the following code in your .htaccess.

RewriteEngine On
RewriteBase /
RewriteRule ^index\.php$ – [L]
RewriteRule ^wp-admin$ wp-admin/ [R=301,L]
RewriteCond %{REQUEST_FILENAME} -f [OR]
RewriteCond %{REQUEST_FILENAME} -d
RewriteRule ^ – [L]
RewriteRule ^(wp-(content|admin|includes).*) $1 [L]
RewriteRule ^(.*\.php)$ $1 [L]
RewriteRule . index.php [L]

Now refresh page and check.

4. Reset permalink for your website with sub-directory

if your website is place in sub-directory of domain means, please place the following code in your .htaccess file.

RewriteEngine On
RewriteBase /
RewriteRule ^index\.php$ – [L]
RewriteRule ^([_0-9a-zA-Z-]+/)?wp-admin$ $1wp-admin/ [R=301,L]
RewriteCond %{REQUEST_FILENAME} -f [OR]
RewriteCond %{REQUEST_FILENAME} -d
RewriteRule ^ – [L]
RewriteRule ^([_0-9a-zA-Z-]+/)?(wp-(content|admin|includes).*) $2 [L]
RewriteRule ^([_0-9a-zA-Z-]+/)?(.*\.php)$ $2 [L]
RewriteRule . index.php [L]

Now refresh page and check.

if nothing is rectified your error then check error log file for the error.

Leave feedback about this

  • Rating