password protect web pageThere are times when you want to password protect a web page, or a whole directory of a website. For example if you have an area of your web site and you don't want the public to have access. You might want to have a paid subscription service. Password protecting a web page works well for this.



Or perhaps you are building a website and you only want certain people to see it. Setting up a directory and password protecting it is a great way to do this. If your web host has a Control Panel: This is most certainly the easy way. My Web hosting company uses cpanel for managing websites.. Almost all of them have some sort of way to password protect a directory. So look into this first.

To password protect a web page directory in Cpanel, just scroll down to the Security section and click on Password Protect Directories.

 

password protect a web page

From there, just follow the prompts.

If this isn't an option, then read on.

But first, there are a few system requirements for which this article will be dealing with.

1. Your website must be running on an Apache web server.

2. Your web host must have enabled .htaccess processing - that is, they allow you to customize your web server environment using localized configuration files called .htaccess files.

3. You must have shell access, either via telnet or Secure Shell (SSH). You should also know how to use telnet or SSH to connect to your web hosting account.