Code · Made a little simpler

Bcrypt Hash Generator

Generate a salted bcrypt hash with a chosen cost or verify one supplied password against an existing $2a$, $2b$ or $2y$ hash in your browser.

Free to useNo account neededProcessed on your device
Your workspaceProcessed on your device

Use up to 72 UTF-8 bytes. Higher costs take longer to run.

Add this tool to your website

Paste this code into your page to add the tool and a visible ToolMellow credit link.

HTML embed code
Preview embed

Bcrypt Hash Generator: how to use it

  1. Enter a test password and choose a cost from 4 through 16. Choose Generate hash to create a fresh random salt and a $2b$ result.
  2. To verify a saved hash, choose Verify one password. Paste the full 60-character hash and enter the candidate, or load the public verification example.
  3. Check the match result, variant, encoded cost and password byte count. Copy or download a generated hash.

Limits and notes

Runs in a worker on this device. Test passwords can contain 1 to 72 UTF-8 bytes on one line without NUL bytes. Overlong passwords are rejected. Verification accepts complete $2a$, $2b$ and $2y$ hashes with cost 4 through 16.

How your privacy works →

Bcrypt Hash Generator: common questions

Why is the hash different each time I click Generate?

The generator uses a fresh random salt each time. The salt is embedded in each result so the original password can still be verified.

How many Unicode characters can bcrypt hash?

The limit is 72 UTF-8 bytes. The number of characters depends on their encoding. For example, 36 copies of é use 72 bytes.

Can bcrypt recover an original password from a hash?

bcrypt checks whether a supplied password corresponds to the hash. It does not provide a reverse operation that reveals the password.

Guides