Knowledgebase

Password Protect Web Directories

  • 2

Do you have content or a folder on your website that you want to secure so that only visitors with valid login details can view the contents? This is easy to do in cPanel using the 'Directory Privacy' feature. In this article, we'll show you how:

 

Step 1- Log into cPanel

Log into your cPanel account with your username and password.

Step 2 - Open 'Password Protect Directories'

Once you have logged into cPanel, under the Security heading click on 'Directory Privacy'

This will display a full directory tree of your site's files

Step 3 - Select Your Directory

Navigate through your folder structure by clicking on the folder icon to the left of a folder name top open it and view its contents. When you have found the folder you wish to password protect, click on its name.

Step 4 - Enable Password Protection

Click the checkbox for 'Password protect this directory' and enter a name (this is a description field that will display when a visitor tries to access your page. Click Save.

You will be presented with a screen saying the permissions have been updated. Click 'Go Back'

 

Step 5 - Set Usernames & Passwords

Enter a username  under 'Create User' and a password. Note that the password must be complex and reach 80 on the complexity scale. Click 'Add/Modify USer' when done to add the user. You can now add as many users as required.


Your web folder is now secure and will require a valid username and password to be able to access it.


Was this answer helpful?