← All text tools

.htpasswd generator

Create .htpasswd lines with bcrypt for Apache and Nginx password protection.

  • Free
  • No sign-up
  • Works on any device

About .htpasswd generator

Enter a username and password and get a line for an .htpasswd file, hashed with bcrypt, for Apache or Nginx basic authentication. Basic auth is a quick way to protect a staging site, but always serve it over HTTPS since the credentials are only Base64 encoded in transit.

How to use .htpasswd generator

  1. Type or paste your text in the box above.
  2. The result appears instantly as you type.
  3. Copy the result or download it as a file.

Why use this tool?

Also known as

Frequently asked questions

Where do I put the .htpasswd file?

Store it outside the public web root, then point AuthUserFile in Apache or auth_basic_user_file in Nginx to its full path.

Is .htpasswd generator free?

Yes. .htpasswd generator on Toolipedia is free to use, with no sign-up and no watermark.

Is it safe to use?

Yes. Everything is worked out in your browser, and nothing you enter is sent to our server.

Does it work on my phone?

Yes. It works in any modern browser on Android and iPhone, as well as on tablets and computers. There's nothing to install.

Do I need an account?

No. Just open the page and use the tool. There's no sign-up and no email needed.

Related tools