When you add password protection to a directory, site visitors are prompted for a username and password when they try to access it. After typing a valid username and password they can only view directory content.
Visitors wishing to access password-protected directories must enter a username and password to view the contents of the directory.
In this article, you will find how to set up a password-protected directory for a domain in Plesk. You can password-protect the directory and place some restrictions on public access to your website.
Note- When you password-protect a directory, any directories beneath it are also password-protected.
Let us follow the steps-
- Log in to Plesk.
- Select the “Websites & Domains” option.
- Select “Password-Protected Directories” from the drop-down menu.
- Click on the “Add Protected Directory” under tools.
- Type the name of the directory you want to protect in the Directory Name text box under Settings.
Note : The directory name should not contain the words httpdocs. Simply type the directory’s name.
Optionally, type a name for the protected directory in the Title of the protected area text box. - Enter the “Title of the protected area”.
- Click on the “Ok” button.
- You will get a success message.
- You will find the list of the directories as shown below.
- Click on the recently added directory.
- Click Add a User under Tools, then type a name for the user in the Username text box under Protected directory user.
- Type the user’s password in the New Password and Confirm Password text fields
- Click on the “Ok” button.
- You will receive a success message.
That’s it!!
This option isn’t limited to just Plesk , you can also set up Directory Privacy in cPanel for securing your files and folders.
For any problem contact our support staff at any moment. Also, take a glance at eukhost latest web hosting plans.