How do I Password Protect a Directory in cPanel

In this article, you may find its best practice to password protect a folder on your account. This can add extra layer of protection to files. Password protecting a directory can be easily  done using the option within cPanel .

 

Step 1: Login to  cPanel

To set password for a directory you need to login the cPanel.

 

 

 

Step 2: Go to the files section and click on the Directory Privacy icon.

 

 

 

Step 3:  Navigate within your directories to find  directory you want to protect .Use icon on the left hand  side to open a directory.

 

 

 

Step 4: Selecting the directory you want to protect by clicking on the name of the folders, you will get confirmation as shown below.

 

 

 

Step 5: Select Password protect for this directory checkbox and enter a Label which you wish to display in the frontend , click Save to protect this directory.

 

 

 

 

Step 6: To give access to users, you will need to create users, Enter username and password  to create a new user, who will have access to this directory from the frontend.

 

 

 

Step 7: Click Save to give access to this user . You can also create more than one user here.

If you now try to access your password protected directory, you will get a prompt like this,

 

 

You can enter the username and password to access this directory.

 

 

 

 

 

Leave a Reply

Your email address will not be published. Required fields are marked *