Wordpress - Does WordPress Change the .htaccess File When Updating?

Generally speaking WordPress will update the .htaccess file any time you change the permalink structure. Many plugins will also update/modify the file as needed.

But the default structure of the .htaccess file allows you to lay it out in such a way that WordPress will not overwrite your custom entries.

WordPress will overwrite the entries between '# BEGIN WordPress' and '# END WordPress'. While most plugins will create their own begin and end tags and only update within those tags.

Simply put your custom entries outside of any custom tags/comments and they SHOULD be preserved when WP updates the file.


No, normally only if you change the permalink structure. Often a plugin is the problem. But you can use an FTP tool, or SSH, to change the access rights of the .htaccess file to something like 644, so that scripts don't change the data.