WordPress is a powerful CMS. Sometimes a small tweak can make your site inaccessible. However, finding a solution for any WordPress problem is very easy (check how to properly ask WordPress support and get it). In the past, we’ve covered some of the most common problems faced by WordPress users. An error has occurred like an internal server error or a database connection. Another common problem that most WordPress users face at certain times is that WordPress posts return a 404 error. In this article, we’ll show you how to fix a WordPress post that returns a 404 error.

Typically in this case, users can access their WordPress admin area to their blog’s home page, but when they access a single post, they get a 404 not found error. First of all, do not panic most of the time your post is still there, completely safe. This usually happens if your .htaccess file is deleted or there is a problem with the rewrite rule. All you need to do is fix the fixed link settings.

Go to Settings »Permalinks, just click the Save Changes button.

Update permalink settings

This will update your fixed link settings and refresh the rewrite rules. In most cases, this solution fixes a WordPress post 404 error. However, if it does not work for you, then you may need to manually update the .htaccess file.
Log in to your server using FTP and modify the .htaccess file located in the same location as the folders where / wp-content / and / wp-includes / is located. The easiest way is to temporarily make the file writable by changing the permissions to 666. Then repeat the original solution. Do not forget to change the permissions to 660. You can also add this code manually in the .htaccess file:

01 # BEGIN WordPress
02 <IfModule mod_rewrite.c>
03 RewriteEngine On
04 RewriteBase /
05 RewriteRule ^index\.php$ - [L]
06 RewriteCond %{REQUEST_FILENAME} !-f
07 RewriteCond %{REQUEST_FILENAME} !-d
08 RewriteRule . /index.php [L]
09 </IfModule>
10 # END WordPress

Repair the local server

Designers and developers typically use a local server to install WordPress on their computers for testing. If you want to use pretty fixed links, you need to enable rewrite_module in the Apache configuration of MAMP, WAMP or XXAMP.