Password protection and Wordpress permalinks issue. How to fix it?

Modified on Wed, 26 Nov at 3:47 PM

When you want to password protect a subfolder of your account, if there is a WordPress application installed in the public_html folder, the rewrite rules of the WordPress application will most likely negate the password protection.

To have the folder properly protected, edit the .htaccess file in your public_html folder and change the bold line below:

# BEGIN WordPress
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /index.php [L]
</IfModule>
# END WordPress

to

RewriteRule ./ /index.php [L]


Once you modify this rewrite rule, the password protection of the inner folder should be working as expected. Clear the cache of your browser and check the modifications on your end.

Was this article helpful?

That’s Great!

Thank you for your feedback

Sorry! We couldn't be helpful

Thank you for your feedback

Let us know how can we improve this article!

Select at least one of the reasons
CAPTCHA verification is required.

Feedback sent

We appreciate your effort and will try to fix the article