How to Fix Permalink Not Working in WordPress Quickly
permalink not working in WordPress, go to Settings > Permalinks and click Save Changes to refresh rewrite rules. If that doesn't work, check your .htaccess file permissions and content to ensure WordPress can write the correct rules.Why This Happens
WordPress uses permalinks to create friendly URLs for your posts and pages. Sometimes, these links stop working because the rewrite rules that WordPress uses to map URLs to content are missing or incorrect. This often happens if the .htaccess file is missing, has wrong permissions, or if the server's rewrite module is disabled.
# Broken .htaccess example # BEGIN WordPress # (missing rewrite rules) # END WordPress
The Fix
To fix permalinks, first go to your WordPress dashboard, then Settings > Permalinks. Without changing anything, click the Save Changes button. This forces WordPress to update the rewrite rules and write them to the .htaccess file.
If this does not work, manually check your .htaccess file in your WordPress root folder. It should contain the correct rewrite rules and be writable by WordPress.
# Correct .htaccess content for WordPress
# 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 WordPressPrevention
Always ensure your .htaccess file has the right permissions (usually 644) and is writable by WordPress during permalink updates. Avoid manually editing permalink structures unless necessary. Also, confirm that your web server has the rewrite module enabled (like mod_rewrite for Apache). Regularly updating WordPress and plugins helps prevent conflicts that can break permalinks.
Related Errors
- 404 Errors on New Posts: Often fixed by flushing rewrite rules as above.
- White Screen After Permalink Change: Check for plugin conflicts by disabling plugins.
- Server 500 Errors: Usually caused by incorrect
.htaccesssyntax or missing rewrite module.