Password Protect a Directory

From Lunarpages Web Hosting Wiki

With your Lunarpages hosting account, along with cPanel, you can password protect your directories. If you wish to keep certain files private, this can be enabled easily through your hosting account's cPanel.

How to Password Protect a Directory in cPanel

Cpanel new security box.png

First step you need to take is login to your hosting account's cPanel. Scroll down to the Security section and click on the icon marked Password Protect Directories.


You will see a list of your folders. Click on the folders to open them, and click on the word to select the folder that you wish to password protect.

Cpanel new passprot 02.png

To enable, click the check box to password protect the directory. Next you need to create a name for the protected directory. This will be the title in the popup window that prompts your user to login. Now click the Save button.

Creating Users and Passwords for a Folder

From the front page of cPanel, go to Password Protect Directories then the folder you wish to protect. Scroll to the bottom section of the page and you will see a box for setting up your users and password for that folder.

Cpanel new passprot 03.png

Fill out the boxes for a username and password to access this folder. The password should be 6-8 alpha-numeric characters and should not include the user name, and the Strength bar will show you how strong it is. Alternatively you can click the Password Generator button to make a random one.

Make sure you take note of the user name and password combination, and then click on the Add/modify authorized user button. Now when trying to access your password protected directory you will use that username and password combination to do so.

To change the password of an existing user, type the identical username in the box, then input the new password twice and click the Add/modify authorized user button.

If you have a user that you would like to delete, under the Authorized User list, select the user and click the Delete button.