{"id":129,"date":"2026-05-26T20:59:17","date_gmt":"2026-05-26T20:59:17","guid":{"rendered":"https:\/\/hostandtech.com\/kb\/wordpress\/fix-404-errors-wordpress-posts-pages\/"},"modified":"2026-05-26T20:59:17","modified_gmt":"2026-05-26T20:59:17","slug":"fix-404-errors-wordpress-posts-pages","status":"publish","type":"post","link":"https:\/\/hostandtech.com\/kb\/wordpress\/fix-404-errors-wordpress-posts-pages\/","title":{"rendered":"Fix 404 Errors on WordPress Posts and Pages"},"content":{"rendered":"<h2>Overview<\/h2>\n<p>A 404 error on WordPress posts and pages is one of the most common issues on fresh installs and after server migrations. Your homepage works, but clicking any post, category, or custom page returns &#8220;404 Not Found.&#8221; The site isn&#8217;t broken \u2014 WordPress just can&#8217;t tell the server how to route those URLs.<\/p>\n<p>The root cause is almost always a corrupted or missing <code class=\"\" data-line=\"\">.htaccess<\/code> file, or a web server that isn&#8217;t processing WordPress rewrite rules correctly. This happens after cPanel migrations, server software upgrades, a PHP version change, or when someone accidentally deletes <code class=\"\" data-line=\"\">.htaccess<\/code> while cleaning up files.<\/p>\n<p>This article covers every fix I&#8217;ve seen work in practice \u2014 from the 30-second permalink flush to manual Apache\/Nginx config corrections on a VPS. Start from the top and work down.<\/p>\n<h2>Prerequisites<\/h2>\n<ul>\n<li>WordPress admin access (username and password for <code class=\"\" data-line=\"\">\/wp-admin<\/code>)<\/li>\n<li>FTP, SFTP, or File Manager access in cPanel or Plesk \u2014 needed if the admin fix doesn&#8217;t work<\/li>\n<li>SSH access if you&#8217;re on a VPS or dedicated server and the rewrite module needs enabling<\/li>\n<li>Know your document root \u2014 typically <code class=\"\" data-line=\"\">\/public_html\/<\/code> on shared hosting or <code class=\"\" data-line=\"\">\/var\/www\/html\/<\/code> on a VPS<\/li>\n<li>WordPress 5.x or later (steps are the same; UI labels match current versions as of 2026)<\/li>\n<\/ul>\n<h2>Step-by-Step Instructions<\/h2>\n<h3>Step 1: Flush WordPress Permalinks<\/h3>\n<p>Do this first \u2014 it fixes the problem 70% of the time and takes 30 seconds.<\/p>\n<ol>\n<li>Log in to your WordPress admin panel at <code class=\"\" data-line=\"\">https:\/\/yourdomain.com\/wp-admin<\/code>.<\/li>\n<li>Go to <strong>Settings \u2192 Permalinks<\/strong>.<\/li>\n<li>Don&#8217;t change anything. Just click <strong>Save Changes<\/strong> at the bottom.<\/li>\n<\/ol>\n<p>This forces WordPress to rewrite the <code class=\"\" data-line=\"\">.htaccess<\/code> file with fresh rewrite rules. Load a post \u2014 if it works, you&#8217;re done.<\/p>\n<p>\ud83d\udcdd Note: If the Save Changes button completes but posts still 404, WordPress couldn&#8217;t write to <code class=\"\" data-line=\"\">.htaccess<\/code>. That means a permissions problem or a read-only file. Move to Step 2.<\/p>\n<h3>Step 2: Check and Fix .htaccess<\/h3>\n<p>Navigate to your WordPress root directory using cPanel File Manager, Plesk File Manager, or an SFTP client like FileZilla.<\/p>\n<ol>\n<li>Open File Manager in cPanel and navigate to <code class=\"\" data-line=\"\">public_html\/<\/code> (or your WordPress install directory).<\/li>\n<li>Make sure hidden files are visible. In cPanel File Manager, click <strong>Settings<\/strong> in the top-right and check <strong>Show Hidden Files (dotfiles)<\/strong>.<\/li>\n<li>Look for a file named <code class=\"\" data-line=\"\">.htaccess<\/code>. If it&#8217;s missing, you need to create it.<\/li>\n<li>Right-click <code class=\"\" data-line=\"\">.htaccess<\/code> and click <strong>Edit<\/strong>. Confirm the content matches the standard WordPress block below. If it&#8217;s empty, has extra content from a plugin conflict, or is missing entirely, replace it with this:<\/li>\n<\/ol>\n<div class='ht-code-snippet'><button class='ht-code-snippet__copy' onclick='htCopyCode(\"code-block-1\")' type='button' aria-label='Copy code'><svg class='ht-copy-icon' viewBox='0 0 32 32' width='16' height='16' fill='currentColor'><path d='M28,10V28H10V10H28m0-2H10a2,2,0,0,0-2,2V28a2,2,0,0,0,2,2H28a2,2,0,0,0,2-2V10a2,2,0,0,0-2-2Z'><\/path><path d='M4,18H2V4A2,2,0,0,1,4,2H18V4H4Z'><\/path><\/svg><svg class='ht-check-icon' viewBox='0 0 32 32' width='16' height='16' fill='currentColor'><path d='M13,24l-9-9,1.414-1.414L13,21.171,26.586,7.586,28,9Z'><\/path><\/svg><\/button><span class='ht-code-snippet__feedback'>Copied to clipboard<\/span><\/p>\n<pre class='ht-code-snippet__code' id='code-block-1'><code class=\"\" data-line=\"\"># BEGIN WordPress\n&lt;IfModule mod_rewrite.c&gt;\nRewriteEngine On\nRewriteBase \/\nRewriteRule ^index.php$ - [L]\nRewriteCond %{REQUEST_FILENAME} !-f\nRewriteCond %{REQUEST_FILENAME} !-d\nRewriteRule . \/index.php [L]\n&lt;\/IfModule&gt;\n# END WordPress<\/code><\/pre>\n<\/div>\n<p>\u26a0 Warning: If WordPress is installed in a subdirectory (e.g. <code class=\"\" data-line=\"\">yourdomain.com\/blog\/<\/code>), the <code class=\"\" data-line=\"\">RewriteBase<\/code> line must reflect that path: <code class=\"\" data-line=\"\">RewriteBase \/blog\/<\/code>. Using <code class=\"\" data-line=\"\">\/<\/code> in a subdirectory install will break things further.<\/p>\n<ol start=\"5\">\n<li>Save the file, then check that its permissions are set to <code class=\"\" data-line=\"\">644<\/code>. Right-click \u2192 <strong>Change Permissions<\/strong> \u2192 enter <code class=\"\" data-line=\"\">644<\/code>.<\/li>\n<\/ol>\n<p>\ud83d\udcdd Note: Permissions of <code class=\"\" data-line=\"\">444<\/code> (read-only) are sometimes set by security plugins like Wordfence or iThemes Security. That&#8217;s why Step 1 didn&#8217;t write the file. Change it to <code class=\"\" data-line=\"\">644<\/code>, flush permalinks again, then you can set it back to <code class=\"\" data-line=\"\">444<\/code> if your security setup requires it.<\/p>\n<h3>Step 3: Verify Apache mod_rewrite Is Enabled (VPS \/ Dedicated Server)<\/h3>\n<p>On shared hosting at Host &#038; Tech, <code class=\"\" data-line=\"\">mod_rewrite<\/code> is enabled by default. If you&#8217;re on a VPS or dedicated server managing your own Apache config, it may not be.<\/p>\n<ol>\n<li>SSH into your server.<\/li>\n<li>Check if the module is active and enable it if not, then restart Apache:<\/li>\n<\/ol>\n<div class='ht-code-snippet'><button class='ht-code-snippet__copy' onclick='htCopyCode(\"code-block-2\")' type='button' aria-label='Copy code'><svg class='ht-copy-icon' viewBox='0 0 32 32' width='16' height='16' fill='currentColor'><path d='M28,10V28H10V10H28m0-2H10a2,2,0,0,0-2,2V28a2,2,0,0,0,2,2H28a2,2,0,0,0,2-2V10a2,2,0,0,0-2-2Z'><\/path><path d='M4,18H2V4A2,2,0,0,1,4,2H18V4H4Z'><\/path><\/svg><svg class='ht-check-icon' viewBox='0 0 32 32' width='16' height='16' fill='currentColor'><path d='M13,24l-9-9,1.414-1.414L13,21.171,26.586,7.586,28,9Z'><\/path><\/svg><\/button><span class='ht-code-snippet__feedback'>Copied to clipboard<\/span><\/p>\n<pre class='ht-code-snippet__code' id='code-block-2'><code class=\"\" data-line=\"\">apache2ctl -M | grep rewrite\nsudo a2enmod rewrite\nsudo systemctl restart apache2<\/code><\/pre>\n<\/div>\n<p>On CentOS\/AlmaLinux with Apache (common on cPanel VPS), check <code class=\"\" data-line=\"\">\/etc\/httpd\/conf\/httpd.conf<\/code> or the relevant virtual host file and confirm this line is present and not commented out:<\/p>\n<div class='ht-code-snippet'><button class='ht-code-snippet__copy' onclick='htCopyCode(\"code-block-3\")' type='button' aria-label='Copy code'><svg class='ht-copy-icon' viewBox='0 0 32 32' width='16' height='16' fill='currentColor'><path d='M28,10V28H10V10H28m0-2H10a2,2,0,0,0-2,2V28a2,2,0,0,0,2,2H28a2,2,0,0,0,2-2V10a2,2,0,0,0-2-2Z'><\/path><path d='M4,18H2V4A2,2,0,0,1,4,2H18V4H4Z'><\/path><\/svg><svg class='ht-check-icon' viewBox='0 0 32 32' width='16' height='16' fill='currentColor'><path d='M13,24l-9-9,1.414-1.414L13,21.171,26.586,7.586,28,9Z'><\/path><\/svg><\/button><span class='ht-code-snippet__feedback'>Copied to clipboard<\/span><\/p>\n<pre class='ht-code-snippet__code' id='code-block-3'><code class=\"\" data-line=\"\">LoadModule rewrite_module modules\/mod_rewrite.so<\/code><\/pre>\n<\/div>\n<h3>Step 4: Check the AllowOverride Directive<\/h3>\n<p>This one trips up a lot of people. Even if <code class=\"\" data-line=\"\">mod_rewrite<\/code> is enabled, Apache won&#8217;t obey <code class=\"\" data-line=\"\">.htaccess<\/code> files unless <code class=\"\" data-line=\"\">AllowOverride<\/code> is set correctly. This is the non-obvious gotcha that the WordPress codex glosses over.<\/p>\n<ol>\n<li>On your server, open the Apache virtual host config for your site, or the main config:<\/li>\n<\/ol>\n<div class='ht-code-snippet'><button class='ht-code-snippet__copy' onclick='htCopyCode(\"code-block-4\")' type='button' aria-label='Copy code'><svg class='ht-copy-icon' viewBox='0 0 32 32' width='16' height='16' fill='currentColor'><path d='M28,10V28H10V10H28m0-2H10a2,2,0,0,0-2,2V28a2,2,0,0,0,2,2H28a2,2,0,0,0,2-2V10a2,2,0,0,0-2-2Z'><\/path><path d='M4,18H2V4A2,2,0,0,1,4,2H18V4H4Z'><\/path><\/svg><svg class='ht-check-icon' viewBox='0 0 32 32' width='16' height='16' fill='currentColor'><path d='M13,24l-9-9,1.414-1.414L13,21.171,26.586,7.586,28,9Z'><\/path><\/svg><\/button><span class='ht-code-snippet__feedback'>Copied to clipboard<\/span><\/p>\n<pre class='ht-code-snippet__code' id='code-block-4'><code class=\"\" data-line=\"\">sudo nano \/etc\/apache2\/sites-available\/yourdomain.com.conf<\/code><\/pre>\n<\/div>\n<p>Or on cPanel-based servers, check <code class=\"\" data-line=\"\">\/usr\/local\/apache\/conf\/httpd.conf<\/code>.<\/p>\n<ol start=\"2\">\n<li>Find the <code class=\"\" data-line=\"\">&lt;Directory&gt;<\/code> block for your document root. It should look like this \u2014 if <code class=\"\" data-line=\"\">AllowOverride<\/code> is set to <code class=\"\" data-line=\"\">None<\/code>, that&#8217;s your problem:<\/li>\n<\/ol>\n<div class='ht-code-snippet'><button class='ht-code-snippet__copy' onclick='htCopyCode(\"code-block-5\")' type='button' aria-label='Copy code'><svg class='ht-copy-icon' viewBox='0 0 32 32' width='16' height='16' fill='currentColor'><path d='M28,10V28H10V10H28m0-2H10a2,2,0,0,0-2,2V28a2,2,0,0,0,2,2H28a2,2,0,0,0,2-2V10a2,2,0,0,0-2-2Z'><\/path><path d='M4,18H2V4A2,2,0,0,1,4,2H18V4H4Z'><\/path><\/svg><svg class='ht-check-icon' viewBox='0 0 32 32' width='16' height='16' fill='currentColor'><path d='M13,24l-9-9,1.414-1.414L13,21.171,26.586,7.586,28,9Z'><\/path><\/svg><\/button><span class='ht-code-snippet__feedback'>Copied to clipboard<\/span><\/p>\n<pre class='ht-code-snippet__code' id='code-block-5'><code class=\"\" data-line=\"\">&lt;Directory \/var\/www\/html\/&gt;\n    Options Indexes FollowSymLinks\n    AllowOverride All\n    Require all granted\n&lt;\/Directory&gt;<\/code><\/pre>\n<\/div>\n<ol start=\"3\">\n<li>Change <code class=\"\" data-line=\"\">AllowOverride None<\/code> to <code class=\"\" data-line=\"\">AllowOverride All<\/code>, save, and restart Apache:<\/li>\n<\/ol>\n<div class='ht-code-snippet'><button class='ht-code-snippet__copy' onclick='htCopyCode(\"code-block-6\")' type='button' aria-label='Copy code'><svg class='ht-copy-icon' viewBox='0 0 32 32' width='16' height='16' fill='currentColor'><path d='M28,10V28H10V10H28m0-2H10a2,2,0,0,0-2,2V28a2,2,0,0,0,2,2H28a2,2,0,0,0,2-2V10a2,2,0,0,0-2-2Z'><\/path><path d='M4,18H2V4A2,2,0,0,1,4,2H18V4H4Z'><\/path><\/svg><svg class='ht-check-icon' viewBox='0 0 32 32' width='16' height='16' fill='currentColor'><path d='M13,24l-9-9,1.414-1.414L13,21.171,26.586,7.586,28,9Z'><\/path><\/svg><\/button><span class='ht-code-snippet__feedback'>Copied to clipboard<\/span><\/p>\n<pre class='ht-code-snippet__code' id='code-block-6'><code class=\"\" data-line=\"\">sudo systemctl restart apache2<\/code><\/pre>\n<\/div>\n<h3>Step 5: Nginx-Specific Fix<\/h3>\n<p>If your server uses Nginx (standalone, not as a reverse proxy in front of Apache), <code class=\"\" data-line=\"\">.htaccess<\/code> files are completely ignored. Nginx needs the rewrite rules in its own config block.<\/p>\n<ol>\n<li>Open your site&#8217;s Nginx server block config, typically at <code class=\"\" data-line=\"\">\/etc\/nginx\/sites-available\/yourdomain.com<\/code>.<\/li>\n<li>Inside the <code class=\"\" data-line=\"\">server {}<\/code> block, make sure this location block exists:<\/li>\n<\/ol>\n<div class='ht-code-snippet'><button class='ht-code-snippet__copy' onclick='htCopyCode(\"code-block-7\")' type='button' aria-label='Copy code'><svg class='ht-copy-icon' viewBox='0 0 32 32' width='16' height='16' fill='currentColor'><path d='M28,10V28H10V10H28m0-2H10a2,2,0,0,0-2,2V28a2,2,0,0,0,2,2H28a2,2,0,0,0,2-2V10a2,2,0,0,0-2-2Z'><\/path><path d='M4,18H2V4A2,2,0,0,1,4,2H18V4H4Z'><\/path><\/svg><svg class='ht-check-icon' viewBox='0 0 32 32' width='16' height='16' fill='currentColor'><path d='M13,24l-9-9,1.414-1.414L13,21.171,26.586,7.586,28,9Z'><\/path><\/svg><\/button><span class='ht-code-snippet__feedback'>Copied to clipboard<\/span><\/p>\n<pre class='ht-code-snippet__code' id='code-block-7'><code class=\"\" data-line=\"\">location \/ {\n    try_files $uri $uri\/ \/index.php?$args;\n}<\/code><\/pre>\n<\/div>\n<ol start=\"3\">\n<li>Save and reload Nginx:<\/li>\n<\/ol>\n<div class='ht-code-snippet'><button class='ht-code-snippet__copy' onclick='htCopyCode(\"code-block-8\")' type='button' aria-label='Copy code'><svg class='ht-copy-icon' viewBox='0 0 32 32' width='16' height='16' fill='currentColor'><path d='M28,10V28H10V10H28m0-2H10a2,2,0,0,0-2,2V28a2,2,0,0,0,2,2H28a2,2,0,0,0,2-2V10a2,2,0,0,0-2-2Z'><\/path><path d='M4,18H2V4A2,2,0,0,1,4,2H18V4H4Z'><\/path><\/svg><svg class='ht-check-icon' viewBox='0 0 32 32' width='16' height='16' fill='currentColor'><path d='M13,24l-9-9,1.414-1.414L13,21.171,26.586,7.586,28,9Z'><\/path><\/svg><\/button><span class='ht-code-snippet__feedback'>Copied to clipboard<\/span><\/p>\n<pre class='ht-code-snippet__code' id='code-block-8'><code class=\"\" data-line=\"\">sudo nginx -t\nsudo systemctl reload nginx<\/code><\/pre>\n<\/div>\n<p>\ud83d\udcdd Note: If you&#8217;re on Host &#038; Tech <a href=\"https:\/\/www.hostandtech.com\/managed-wordpress-hosting\/\">Managed WordPress Hosting<\/a>, the Nginx config is managed for you and this won&#8217;t be the cause. Open a support ticket instead \u2014 something else is going on.<\/p>\n<h2>Common Issues and Troubleshooting<\/h2>\n<h3>Permalinks Save but Posts Still 404<\/h3>\n<p><strong>Cause:<\/strong> WordPress saved the settings but couldn&#8217;t update <code class=\"\" data-line=\"\">.htaccess<\/code> \u2014 either due to file permissions or because the file is owned by a different system user after a server migration.<\/p>\n<p><strong>Fix:<\/strong> Manually replace <code class=\"\" data-line=\"\">.htaccess<\/code> with the standard WordPress block from Step 2. Then verify the file owner via SSH with <code class=\"\" data-line=\"\">ls -la \/public_html\/.htaccess<\/code>. The owner should match your cPanel username. If it shows <code class=\"\" data-line=\"\">root<\/code>, run <code class=\"\" data-line=\"\">sudo chown yourusername:yourusername \/public_html\/.htaccess<\/code>.<\/p>\n<h3>Only the Homepage Works, All Other Pages Are 404<\/h3>\n<p><strong>Cause:<\/strong> This is the classic symptom of <code class=\"\" data-line=\"\">mod_rewrite<\/code> not being active, or <code class=\"\" data-line=\"\">AllowOverride None<\/code> blocking <code class=\"\" data-line=\"\">.htaccess<\/code> entirely. The homepage loads because it hits <code class=\"\" data-line=\"\">index.php<\/code> directly.<\/p>\n<p><strong>Fix:<\/strong> Follow Steps 3 and 4. If you&#8217;re on shared hosting and don&#8217;t have SSH access, contact support \u2014 this is a server configuration issue you can&#8217;t fix from cPanel alone.<\/p>\n<h3>404 Errors After Moving WordPress to a Subdirectory<\/h3>\n<p><strong>Cause:<\/strong> The <code class=\"\" data-line=\"\">RewriteBase<\/code> in <code class=\"\" data-line=\"\">.htaccess<\/code> is still set to <code class=\"\" data-line=\"\">\/<\/code> but WordPress is now at <code class=\"\" data-line=\"\">\/blog\/<\/code> or another subdirectory.<\/p>\n<p><strong>Fix:<\/strong> Update <code class=\"\" data-line=\"\">RewriteBase<\/code> to match the subdirectory path. Also confirm that the WordPress Address (URL) and Site Address (URL) in <strong>Settings \u2192 General<\/strong> reflect the correct paths.<\/p>\n<h3>404 After Updating Permalink Structure<\/h3>\n<p><strong>Cause:<\/strong> Changing from one permalink structure (e.g. <code class=\"\" data-line=\"\">?p=123<\/code>) to another (e.g. <code class=\"\" data-line=\"\">\/post-name\/<\/code>) requires the <code class=\"\" data-line=\"\">.htaccess<\/code> file to be rewritten. If the file isn&#8217;t writable at that moment, old rules stay in place.<\/p>\n<p><strong>Fix:<\/strong> After changing permalink structure, immediately go back to <strong>Settings \u2192 Permalinks<\/strong> and click <strong>Save Changes<\/strong> a second time. If the file still doesn&#8217;t update, replace it manually using the block in Step 2.<\/p>\n<h3>Custom Post Types Returning 404<\/h3>\n<p><strong>Cause:<\/strong> When a plugin registers a custom post type, WordPress needs to flush rewrite rules to register the new URL patterns. This often gets missed on first activation.<\/p>\n<p><strong>Fix:<\/strong> Go to <strong>Settings \u2192 Permalinks<\/strong> and click <strong>Save Changes<\/strong> \u2014 no other changes needed. This is a known quirk: any time you activate a plugin that adds custom post types or taxonomies, you should flush permalinks immediately after.<\/p>\n<h2>FAQ<\/h2>\n<div class='ht-faq-section'>\n<h2>Frequently Asked Questions<\/h2>\n<div class='ht-faq-item'>\n<h3 class='ht-faq-question'>Why does my WordPress homepage work but all other pages show 404?<\/h3>\n<div class='ht-faq-answer'>\n<p>This almost always means Apache&#8217;s mod_rewrite module isn&#8217;t active, or the AllowOverride directive is set to None \u2014 so the server ignores the rewrite rules in your .htaccess file. The homepage loads because it resolves directly to index.php. Enable mod_rewrite and set AllowOverride to All in your Apache config to fix it.<\/p>\n<\/div>\n<\/div>\n<div class='ht-faq-item'>\n<h3 class='ht-faq-question'>How do I fix a 404 error in WordPress without cPanel access?<\/h3>\n<div class='ht-faq-answer'>\n<p>You can fix most 404 issues directly from the WordPress admin by going to Settings \u2192 Permalinks and clicking Save Changes. If that doesn&#8217;t work and you don&#8217;t have cPanel access, use an FTP client like FileZilla to access your site root and manually edit or replace the .htaccess file with the standard WordPress rewrite block.<\/p>\n<\/div>\n<\/div>\n<div class='ht-faq-item'>\n<h3 class='ht-faq-question'>Can a plugin cause 404 errors on WordPress posts?<\/h3>\n<div class='ht-faq-answer'>\n<p>Yes \u2014 security plugins like Wordfence or iThemes Security can set .htaccess to read-only (permissions 444), which prevents WordPress from updating it. Some caching or redirect plugins also inject conflicting rules into .htaccess. Try deactivating plugins one by one or checking .htaccess for anything that doesn&#8217;t belong in the standard WordPress block.<\/p>\n<\/div>\n<\/div>\n<div class='ht-faq-item'>\n<h3 class='ht-faq-question'>Why did I start getting 404 errors after migrating my WordPress site?<\/h3>\n<div class='ht-faq-answer'>\n<p>Migrations commonly cause 404s for two reasons: the .htaccess file didn&#8217;t transfer correctly, or the file ownership changed so WordPress can&#8217;t write to it. Check that .htaccess exists in your WordPress root, contains the correct rewrite rules, has permissions set to 644, and is owned by your hosting account user \u2014 not root.<\/p>\n<\/div>\n<\/div>\n<div class='ht-faq-item'>\n<h3 class='ht-faq-question'>Do I need to edit .htaccess if my server uses Nginx?<\/h3>\n<div class='ht-faq-answer'>\n<p>No \u2014 Nginx ignores .htaccess files completely. If your site runs on Nginx, the WordPress rewrite rules need to be added directly to your Nginx server block config using a try_files directive. Editing .htaccess on an Nginx server will have zero effect on your 404 errors.<\/p>\n<\/div>\n<\/div>\n<\/div>\n","protected":false},"excerpt":{"rendered":"<p>Your homepage loads fine but every post and page throws a 404. It&#8217;s a classic WordPress permalink problem \u2014 and it&#8217;s almost always fixable in under five minutes. Here&#8217;s exactly what to do.<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"site-sidebar-layout":"default","site-content-layout":"","ast-site-content-layout":"default","site-content-style":"default","site-sidebar-style":"default","ast-global-header-display":"","ast-banner-title-visibility":"","ast-main-header-display":"","ast-hfb-above-header-display":"","ast-hfb-below-header-display":"","ast-hfb-mobile-header-display":"","site-post-title":"","ast-breadcrumbs-content":"","ast-featured-img":"","footer-sml-layout":"","ast-disable-related-posts":"","theme-transparent-header-meta":"","adv-header-id-meta":"","stick-header-meta":"","header-above-stick-meta":"","header-main-stick-meta":"","header-below-stick-meta":"","astra-migrate-meta-layouts":"default","ast-page-background-enabled":"default","ast-page-background-meta":{"desktop":{"background-color":"var(--ast-global-color-5)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"tablet":{"background-color":"","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"mobile":{"background-color":"","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""}},"ast-content-background-meta":{"desktop":{"background-color":"var(--ast-global-color-4)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"tablet":{"background-color":"var(--ast-global-color-4)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"mobile":{"background-color":"var(--ast-global-color-4)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""}},"footnotes":""},"categories":[91],"tags":[141,140,142,138,137,136,139,121],"class_list":["post-129","post","type-post","status-publish","format-standard","hentry","category-wordpress","tag-404-error-on-posts-pages","tag-broken-pages-wordpress","tag-fix-404-errors-on-wordpress-posts-and-pages","tag-htaccess-wordpress","tag-permalink-fix","tag-wordpress-404-error","tag-wordpress-rewrite-rules","tag-wordpress-troubleshooting"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v27.6 - https:\/\/yoast.com\/product\/yoast-seo-wordpress\/ -->\n<title>Fix 404 Errors on WordPress Posts and Pages<\/title>\n<meta name=\"description\" content=\"Getting a 404 error on WordPress posts and pages? Here&#039;s how to fix broken permalinks, .htaccess issues, and server misconfigs fast.\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/hostandtech.com\/kb\/wordpress\/fix-404-errors-wordpress-posts-pages\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Fix 404 Errors on WordPress Posts and Pages\" \/>\n<meta property=\"og:description\" content=\"Getting a 404 error on WordPress posts and pages? Here&#039;s how to fix broken permalinks, .htaccess issues, and server misconfigs fast.\" \/>\n<meta property=\"og:url\" content=\"https:\/\/hostandtech.com\/kb\/wordpress\/fix-404-errors-wordpress-posts-pages\/\" \/>\n<meta property=\"og:site_name\" content=\"Host And Tech knowledge base\" \/>\n<meta property=\"article:publisher\" content=\"https:\/\/www.facebook.com\/stshostandtech\" \/>\n<meta property=\"article:published_time\" content=\"2026-05-26T20:59:17+00:00\" \/>\n<meta name=\"author\" content=\"admin\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:creator\" content=\"@stshostandtech\" \/>\n<meta name=\"twitter:site\" content=\"@stshostandtech\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"admin\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"8 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\\\/\\\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\\\/\\\/hostandtech.com\\\/kb\\\/wordpress\\\/fix-404-errors-wordpress-posts-pages\\\/#article\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/hostandtech.com\\\/kb\\\/wordpress\\\/fix-404-errors-wordpress-posts-pages\\\/\"},\"author\":{\"name\":\"admin\",\"@id\":\"https:\\\/\\\/hostandtech.com\\\/kb\\\/#\\\/schema\\\/person\\\/b6fa79c48ddaba71af32e395c5b017ee\"},\"headline\":\"Fix 404 Errors on WordPress Posts and Pages\",\"datePublished\":\"2026-05-26T20:59:17+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\\\/\\\/hostandtech.com\\\/kb\\\/wordpress\\\/fix-404-errors-wordpress-posts-pages\\\/\"},\"wordCount\":1389,\"commentCount\":0,\"publisher\":{\"@id\":\"https:\\\/\\\/hostandtech.com\\\/kb\\\/#organization\"},\"keywords\":[\"404 error on posts\\\/pages\",\"broken pages wordpress\",\"Fix 404 Errors on WordPress Posts and Pages\",\"htaccess wordpress\",\"permalink fix\",\"wordpress 404 error\",\"wordpress rewrite rules\",\"WordPress troubleshooting\"],\"articleSection\":[\"WordPress Hosting\"],\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"CommentAction\",\"name\":\"Comment\",\"target\":[\"https:\\\/\\\/hostandtech.com\\\/kb\\\/wordpress\\\/fix-404-errors-wordpress-posts-pages\\\/#respond\"]}]},{\"@type\":\"WebPage\",\"@id\":\"https:\\\/\\\/hostandtech.com\\\/kb\\\/wordpress\\\/fix-404-errors-wordpress-posts-pages\\\/\",\"url\":\"https:\\\/\\\/hostandtech.com\\\/kb\\\/wordpress\\\/fix-404-errors-wordpress-posts-pages\\\/\",\"name\":\"Fix 404 Errors on WordPress Posts and Pages\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/hostandtech.com\\\/kb\\\/#website\"},\"datePublished\":\"2026-05-26T20:59:17+00:00\",\"description\":\"Getting a 404 error on WordPress posts and pages? Here's how to fix broken permalinks, .htaccess issues, and server misconfigs fast.\",\"breadcrumb\":{\"@id\":\"https:\\\/\\\/hostandtech.com\\\/kb\\\/wordpress\\\/fix-404-errors-wordpress-posts-pages\\\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\\\/\\\/hostandtech.com\\\/kb\\\/wordpress\\\/fix-404-errors-wordpress-posts-pages\\\/\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\\\/\\\/hostandtech.com\\\/kb\\\/wordpress\\\/fix-404-errors-wordpress-posts-pages\\\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\\\/\\\/hostandtech.com\\\/kb\\\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Fix 404 Errors on WordPress Posts and Pages\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\\\/\\\/hostandtech.com\\\/kb\\\/#website\",\"url\":\"https:\\\/\\\/hostandtech.com\\\/kb\\\/\",\"name\":\"Host And Tech knowledge base\",\"description\":\"\",\"publisher\":{\"@id\":\"https:\\\/\\\/hostandtech.com\\\/kb\\\/#organization\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\\\/\\\/hostandtech.com\\\/kb\\\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":\"Organization\",\"@id\":\"https:\\\/\\\/hostandtech.com\\\/kb\\\/#organization\",\"name\":\"Host And Tech knowledge base\",\"url\":\"https:\\\/\\\/hostandtech.com\\\/kb\\\/\",\"logo\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/hostandtech.com\\\/kb\\\/#\\\/schema\\\/logo\\\/image\\\/\",\"url\":\"https:\\\/\\\/hostandtech.com\\\/kb\\\/wp-content\\\/uploads\\\/2026\\\/05\\\/logo-dark.png\",\"contentUrl\":\"https:\\\/\\\/hostandtech.com\\\/kb\\\/wp-content\\\/uploads\\\/2026\\\/05\\\/logo-dark.png\",\"width\":1134,\"height\":395,\"caption\":\"Host And Tech knowledge base\"},\"image\":{\"@id\":\"https:\\\/\\\/hostandtech.com\\\/kb\\\/#\\\/schema\\\/logo\\\/image\\\/\"},\"sameAs\":[\"https:\\\/\\\/www.facebook.com\\\/stshostandtech\",\"https:\\\/\\\/x.com\\\/stshostandtech\"]},{\"@type\":\"Person\",\"@id\":\"https:\\\/\\\/hostandtech.com\\\/kb\\\/#\\\/schema\\\/person\\\/b6fa79c48ddaba71af32e395c5b017ee\",\"name\":\"admin\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/aa1edac8bbadb442e059a5b65ad45a3b2e3ce689202373b96e3e567517ae4b39?s=96&d=mm&r=g\",\"url\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/aa1edac8bbadb442e059a5b65ad45a3b2e3ce689202373b96e3e567517ae4b39?s=96&d=mm&r=g\",\"contentUrl\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/aa1edac8bbadb442e059a5b65ad45a3b2e3ce689202373b96e3e567517ae4b39?s=96&d=mm&r=g\",\"caption\":\"admin\"},\"sameAs\":[\"https:\\\/\\\/hostandtech.com\\\/kb\"],\"url\":\"https:\\\/\\\/hostandtech.com\\\/kb\\\/author\\\/admin_fjj7qydm\\\/\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"Fix 404 Errors on WordPress Posts and Pages","description":"Getting a 404 error on WordPress posts and pages? Here's how to fix broken permalinks, .htaccess issues, and server misconfigs fast.","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/hostandtech.com\/kb\/wordpress\/fix-404-errors-wordpress-posts-pages\/","og_locale":"en_US","og_type":"article","og_title":"Fix 404 Errors on WordPress Posts and Pages","og_description":"Getting a 404 error on WordPress posts and pages? Here's how to fix broken permalinks, .htaccess issues, and server misconfigs fast.","og_url":"https:\/\/hostandtech.com\/kb\/wordpress\/fix-404-errors-wordpress-posts-pages\/","og_site_name":"Host And Tech knowledge base","article_publisher":"https:\/\/www.facebook.com\/stshostandtech","article_published_time":"2026-05-26T20:59:17+00:00","author":"admin","twitter_card":"summary_large_image","twitter_creator":"@stshostandtech","twitter_site":"@stshostandtech","twitter_misc":{"Written by":"admin","Est. reading time":"8 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/hostandtech.com\/kb\/wordpress\/fix-404-errors-wordpress-posts-pages\/#article","isPartOf":{"@id":"https:\/\/hostandtech.com\/kb\/wordpress\/fix-404-errors-wordpress-posts-pages\/"},"author":{"name":"admin","@id":"https:\/\/hostandtech.com\/kb\/#\/schema\/person\/b6fa79c48ddaba71af32e395c5b017ee"},"headline":"Fix 404 Errors on WordPress Posts and Pages","datePublished":"2026-05-26T20:59:17+00:00","mainEntityOfPage":{"@id":"https:\/\/hostandtech.com\/kb\/wordpress\/fix-404-errors-wordpress-posts-pages\/"},"wordCount":1389,"commentCount":0,"publisher":{"@id":"https:\/\/hostandtech.com\/kb\/#organization"},"keywords":["404 error on posts\/pages","broken pages wordpress","Fix 404 Errors on WordPress Posts and Pages","htaccess wordpress","permalink fix","wordpress 404 error","wordpress rewrite rules","WordPress troubleshooting"],"articleSection":["WordPress Hosting"],"inLanguage":"en-US","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/hostandtech.com\/kb\/wordpress\/fix-404-errors-wordpress-posts-pages\/#respond"]}]},{"@type":"WebPage","@id":"https:\/\/hostandtech.com\/kb\/wordpress\/fix-404-errors-wordpress-posts-pages\/","url":"https:\/\/hostandtech.com\/kb\/wordpress\/fix-404-errors-wordpress-posts-pages\/","name":"Fix 404 Errors on WordPress Posts and Pages","isPartOf":{"@id":"https:\/\/hostandtech.com\/kb\/#website"},"datePublished":"2026-05-26T20:59:17+00:00","description":"Getting a 404 error on WordPress posts and pages? Here's how to fix broken permalinks, .htaccess issues, and server misconfigs fast.","breadcrumb":{"@id":"https:\/\/hostandtech.com\/kb\/wordpress\/fix-404-errors-wordpress-posts-pages\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/hostandtech.com\/kb\/wordpress\/fix-404-errors-wordpress-posts-pages\/"]}]},{"@type":"BreadcrumbList","@id":"https:\/\/hostandtech.com\/kb\/wordpress\/fix-404-errors-wordpress-posts-pages\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/hostandtech.com\/kb\/"},{"@type":"ListItem","position":2,"name":"Fix 404 Errors on WordPress Posts and Pages"}]},{"@type":"WebSite","@id":"https:\/\/hostandtech.com\/kb\/#website","url":"https:\/\/hostandtech.com\/kb\/","name":"Host And Tech knowledge base","description":"","publisher":{"@id":"https:\/\/hostandtech.com\/kb\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/hostandtech.com\/kb\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Organization","@id":"https:\/\/hostandtech.com\/kb\/#organization","name":"Host And Tech knowledge base","url":"https:\/\/hostandtech.com\/kb\/","logo":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/hostandtech.com\/kb\/#\/schema\/logo\/image\/","url":"https:\/\/hostandtech.com\/kb\/wp-content\/uploads\/2026\/05\/logo-dark.png","contentUrl":"https:\/\/hostandtech.com\/kb\/wp-content\/uploads\/2026\/05\/logo-dark.png","width":1134,"height":395,"caption":"Host And Tech knowledge base"},"image":{"@id":"https:\/\/hostandtech.com\/kb\/#\/schema\/logo\/image\/"},"sameAs":["https:\/\/www.facebook.com\/stshostandtech","https:\/\/x.com\/stshostandtech"]},{"@type":"Person","@id":"https:\/\/hostandtech.com\/kb\/#\/schema\/person\/b6fa79c48ddaba71af32e395c5b017ee","name":"admin","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/secure.gravatar.com\/avatar\/aa1edac8bbadb442e059a5b65ad45a3b2e3ce689202373b96e3e567517ae4b39?s=96&d=mm&r=g","url":"https:\/\/secure.gravatar.com\/avatar\/aa1edac8bbadb442e059a5b65ad45a3b2e3ce689202373b96e3e567517ae4b39?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/aa1edac8bbadb442e059a5b65ad45a3b2e3ce689202373b96e3e567517ae4b39?s=96&d=mm&r=g","caption":"admin"},"sameAs":["https:\/\/hostandtech.com\/kb"],"url":"https:\/\/hostandtech.com\/kb\/author\/admin_fjj7qydm\/"}]}},"_links":{"self":[{"href":"https:\/\/hostandtech.com\/kb\/wp-json\/wp\/v2\/posts\/129","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/hostandtech.com\/kb\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/hostandtech.com\/kb\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/hostandtech.com\/kb\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/hostandtech.com\/kb\/wp-json\/wp\/v2\/comments?post=129"}],"version-history":[{"count":0,"href":"https:\/\/hostandtech.com\/kb\/wp-json\/wp\/v2\/posts\/129\/revisions"}],"wp:attachment":[{"href":"https:\/\/hostandtech.com\/kb\/wp-json\/wp\/v2\/media?parent=129"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/hostandtech.com\/kb\/wp-json\/wp\/v2\/categories?post=129"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/hostandtech.com\/kb\/wp-json\/wp\/v2\/tags?post=129"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}