skip to Main Content

How to Setup Directory Privacy in cPanel 2025

cPanel provides a simple way to password-protect specific directories on your website. This is useful for restricting access to sensitive content or private sections of your site.

Follow these step-by-step instructions to enable Directory Privacy in cPanel:

✅ Step-by-Step Instructions

  1. Log in to your cPanel account.

  2. Navigate to Files > Directory Privacy or open File Manager and right-click on the folder you want to protect.

How to Setup Directory Privacy in cPanel

  1. Browse and select the directory you want to secure by clicking on its name.

How to Setup Directory Privacy in cPanel

  1. Click Edit next to the selected folder.

  2. Under Security Settings:

    • Check the box that says “Password protect this directory”.

    • In the “Enter a name for the protected directory” field, provide a label (e.g., “Admin Panel”).

How to Setup Directory Privacy in cPanel

 

  1. Click Save.

👤 Create a User for Access

Once the directory is protected, you’ll need to create a user who can log in:

  1. Click the Go Back link after saving.

  2. Under Create User:

    • Enter a username.

    • Choose a password and confirm it in the respective fields.

How to Setup Directory Privacy in cPanel

  1. Click Save to finalize user creation.

✅ You’re Done!

Your selected directory is now protected. Anyone trying to access it via the browser will be prompted to enter the username and password you

⚠️ Note:
This method adds a basic level of protection. It should not replace proper security practices such as SSL, strong passwords, and secure coding standards for web applications.

Latest Articles
September 15, 2025

How to Add Profile Picture in Webmail Using Gravatar

Having a professional email address is important, but adding a profile picture makes it even more personal and trustworthy. In…

August 23, 2025

How to Disable Copy Paste in WordPress (Step by Step Guide)

On many websites, you might have noticed that the content cannot be copied or selected. Even when you right-click, options…

August 22, 2025

🚀 How to Fix “Unknown collation: ‘utf8mb4_0900_ai_ci’” in cPanel

If you use MySQL or MariaDB, you might have encountered the following error: Unknown collation: 'utf8mb4_0900_ai_ci' 🔎 Why This Happens…

Subscribe To Our Newsletter

Don't get left out of the loop, make sure you subscribe to our newsletter below so you can be notified of our latest insights, tips, tutorials, sales and more!

Discussion
Back To Top