Context
A website under construction, a test version, a folder of private documents or an administration area do not need to be visible to everyone. Password protecting a folder asks for a login from anyone who tries to open it, before the page even shows.
On your Winheberg web hosting, Plesk sets up this protection without touching your website code. The browser shows a login window, and only the users you created can get in.
This guide covers protecting a folder, creating the allowed users and the precautions to take.
The Winheberg Plesk panel is displayed in French. Menu, field and button names are quoted below exactly as they appear on screen, followed by their English meaning.
Prerequisites
- A Winheberg web hosting plan with access to the Plesk panel
- The path of the folder to protect, for instance
/privateforexample.com/private
The browser sends the login and password with every page. Without HTTPS, they travel in clear text. First install the free certificate of your domain with our guide How to Generate a Let's Encrypt SSL Certificate for Your Website
1. Open the protected directories
Open your domain from Sites Web & Domaines (Websites & Domains). In the Tableau de bord (Dashboard), Sécurité (Security) section, click Répertoires protégés par un mot de passe (Password-Protected Directories).
The list already contains /plesk-stat, the folder of your website statistics, protected by default. Leave it as it is.
2. Protect a folder
Click Ajouter un répertoire protégé (Add Protected Directory).
| Field | What to enter |
|---|---|
| Nom du répertoire (Directory name) | The folder path from the website root, for instance /private, or / to protect the whole website |
| Titre de la zone protégée (Protected area title) | A label to find your way, which some browsers show in the login window |
Click Créer (Create). The folder shows in the list, but nobody can get in yet.
3. Add the allowed users
In the list, click the name of the protected folder, then Ajouter un utilisateur (Add User).
Enter a Nom d'utilisateur (User name), click Générer (Generate) to get a strong password and write it down, then click Créer. Repeat for each person, each with their own login.
4. Test the protection
Open the folder address in a private browsing window, for instance https://example.com/private. The browser should ask for a login and password before showing anything.
To remove the protection, tick the folder in the list, then click Supprimer la protection (Remove Protection). The folder and its content stay in place.
Troubleshooting
❌ The login window keeps coming back
The server rejects the credentials entered.
- Check the user name, it is case sensitive
- Set a new password for this user from the folder user list
- Close all browser windows, it sometimes keeps an old password in memory
❌ Part of the WordPress website stops working
The /wp-admin folder is protected, while some functions of the public website go through it.
- Protect the whole website instead while it is under construction, with
/as directory name - To secure the administration of a live website, prefer strong passwords and the WP Toolkit security measures
Best practices
- Protect the whole website while it is under construction, then remove the protection when it goes live
- Create one user per person, so you can remove an access without changing the others
- Delete the users who no longer need access
- Do not rely on this protection for highly sensitive data, keep it outside your public webspace instead
Need help?
If the protection does not apply or blocks part of your website, open a ticket with our support from your client area, Technical department, filling in the Related Product field with the web hosting concerned. Mention the path of the protected folder.
Your private pages stay private, without a line of code 🔒


