Ready to get started?Download WordPress


Basic Password to access blog (2 posts)

  1. samhankin
    Posted 1 year ago #


    Does anyone know of a plugin that will allow me to have one simple password to block access to the whole of my site.

    For example if someone went to blog.website.com they would be presented with a password box only. They would then have to type in the password to get into the blog.

    I only need one password to allow everyone access.


  2. threestyler
    Posted 1 year ago #

    Your host probably provides a quick way to do this via your control panel.

    Otherwise create a file called: .htpasswd

    Inside add your username and password:

    Save the file ABOVE public_html directory so it is not publicly accessible.

    ie if your site is located:
    Put the .htpasswd file:

    Then in your .htaccess file (located in the root of the directory you want to protect) add:

    Authtype Basic
    AuthName "Protected directory"
    AuthUserFile /path/to/your/.htpasswd
    Require user username

    Changing username for either your username in the .htpasswd file or valid-user if you plan to have several user accounts.

Topic Closed

This topic has been closed to new replies.

About this Topic


No tags yet.