How do I password protect my web site (or a directory within)?

Password protecting a directory restricts access to that folder on your website, by requiring visitors to enter a username and a password. This password process is also referred to as a type of “authentication” process.

We recommend that you only password protect directories and not your entire web site as it may cause conflicts with trying to reach your Control Panel or Webmail.

NOTE: Do not create or password protect the following directories: 

  • cpanel
  • webmail
  • webdisk
  • stats

To password protect your directory

Password Protect1. Log into your cPanel and click on the File Manager. Create a new folder within the /public_html folder.

2. Right click on the Folder. A popup menu will open. Choose Password Protect.

3. Click the desired folder's name to open it.

NOTE: A protected directory's subdirectories inherit their parent directory's password protection.

4. Enter a display label for the directory in the Enter a name for the protected directory: text box.

NOTE: This name only serves as a label for the directory, rather than the directory's actual name.

5. Click Save to save the directory's permissions.


Create a user

To create an authorized user for the directory, perform the following steps:

  1. Enter the desired username in the Username text box.

  2. Enter and confirm the new password in the appropriate text boxes.

  3. Click Save to save the user's information.

Remove password protection

To remove password protection from the directory, deselect the Password protect this directory checkbox in the Security Settings section of the interface and click Save.


Delete a user

To delete an authorized user, select a user in the Authorized Users table and click Delete User.

  • 0 Users Found This Useful
Was this answer helpful?

Related Articles

Is it ok to use uppercase letters in an email address?

While most receiving email providers are fine with uppercase characters, some may not be. The...

How do I view or change my FTP or cPanel password?

The username and password for your cPanel login and FTP login are the same. You can view your...

How much disk space is my site using?

This interface displays information about how you use your account's disk space, and all of your...

Can I host more than one website on my account?

Only some web hosting packages allow you to host multiple unique web sites on one cPanel account...

How do I access my cPanel?

There are two ways to access your Control Panel (cPanel). These instructions assume your email...