I've a question about the .htaccess file...

I'm configuring a website and it all works fine, except when I change the .htaccess file. Every time I refresh the page, WordPress overwrites the default .htaccess:

# 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]
# END WordPress

So all the directives that I put in .htaccess are lost because WordPress rewrites the file.

Why this is occurring?

May be a hack?


manual modifications of .htaccess must be done after "# END WordPress" to not be overwrited

  • 2
    or before # BEGIN WordPress. putting it after probably won't work so well ;) – Milo Jul 1 '15 at 20:55

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.