Password Protect a directory using Cpanel
1. Login to the Cpanel account of the domain containing the directory you want to password protect.
"Password Protect Directories". This brings you to the "Allow access only to authorized users" page.
This image is hidden for guests.
Please log in or register to see it.
3. From this page, click on the directory icon to view what's inside the directory or click on the directory name to apply a password to that particular directory. Let's assume we're clicking on the directory name of
"public_html" and password protecting the entire directory.
4. From this page, at the bottom you will see two text boxes allowing you to type in a
"username" and a "password". Fill these boxes in and click the "Add/Modify authorized User" button.
This image is hidden for guests.
Please log in or register to see it.
5. You will then be brought to a confirmation page stating the username and password you have chosen. Please verify them and click
"Go Back".
"Active Users" you will now see your chosen username. You may add multiple usernames and passwords in this manner so that you don't have to give out personal information. You can have one for yourself and one for your client or partner for example.
7. Now, from this page showing the Active usernames, in the section above with the lock icon, check this box,
This image is hidden for guests.
Please log in or register to see it.
leave the next text box blank, then click "Save".
8. You will be brought to a confirmation page and may click
"Go Back".
"Password Protect Directories" page through your Cpanel account, you should now see a lock icon next to the directory you protected (
This image is hidden for guests.
Please log in or register to see it.
), if not, try these steps again.
Congratulations! You now have a password protected directory!