How to use cPanel to Protect Directories with a Password

This article describes how to use cPanel to protect specific directories with a password. Visitors to password-protected directories must enter a username and password to view the directory's contents. This feature is available with every web hosting plan offered by Inspedium.

ADDING PASSWORD PROTECTION TO A DIRECTORY

When you add password protection to a directory, you provide a name for the directory that will appear in users' web browsers when they are prompted for a username and password. Then you create users and passwords to specify who can access the directory.

Note: When you protect a directory with a password, all directories beneath it are automatically protected as well.

To add password protection to a directory, follow these steps:

  1. Log in to cPanel.
  2. In the FILES section of the cPanel home screen, click Directory Privacy.

Note: If you are using the x3 cPanel theme instead, in the Security section of the cPanel home screen, click Password Protect Directories.

      3. Click the name of the directory that you want to protect.

  • You can click the folder icon next to a folder name to open the folder.

      4. Under Security Settings, select the Password protect this directory check box.
      5. In the Enter a name for the protected directory text box, type a name for the protected directory.
      6. Click Save.
      7. Under Create User, type a username in the Username text box.
      8. In the New Password text box, type the user's password.
      9. In the Confirm Password text box, retype the user's password.

Note: You can click Password Generator and cPanel generates a random, strong password for you.

     10. Click Save.

  • You can add multiple users to a password-protected directory.

REMOVING PASSWORD PROTECTION FROM A DIRECTORY

You can remove password protection from a directory when you no longer want to protect it with a password. You do not need to remove the usernames and passwords that you created for the directory. All usernames and passwords are retained when you remove password protection from the directory, but they become inactive. If you subsequently re-enable password protection for the directory, you can use the same usernames and passwords again.

To remove password protection from a directory, follow these steps:

  1. Log in to cPanel.
  2. In the FILES section of the cPanel home screen, click Directory Privacy.

Note: If you are using the x3 cPanel theme instead, in the Security section of the cPanel home screen, click Password Protect Directories.

      4. Click the name of the directory for which you want to remove password protection.
      5. Under Security Settings, clear the Password protect this directory check box.
      6. Click Save.

  • cpanel, .htaccess, password protected directories, password protect
  • 0 Users Found This Useful
Was this answer helpful?

Related Articles

How do I access my CPanel

Every Inspedium Web Hosting Plan comes with CPanel as the hosting control panel. You can access...

How do I update my contact information in CPanel?

To update your contact information in cPanel, you can use the Update Contact Information feature...

How do I change the language of my CPanel?

You can use the Change Language feature to change the default display language of your CPanel...

How to Log in and Log out of cPanel

This article describes how to log in and log out of cPanel. LOGGING IN TO CPANEL To log in to...

Getting familiar with the cPanel Home Screen

This article is an introduction to the cPanel home screen, which is the place to start for...

Powered by WHMCompleteSolution