About Bcrypt Generator
Bcrypt is the password hashing scheme behind many login systems. Type a password, pick a cost, and get a hash ready for a database seed, a config file or a test fixture. Switch to Verify to paste a hash from your user table and see whether a password produces it.
The hashing runs in your browser on a background thread. The password and the hash stay on your device.
How it works
- A new 16-byte salt is drawn from the browser’s secure random source for every hash, and the password is run through bcrypt’s expensive key setup 2 to the power of the cost times.
- The result is written in the usual $2b$ format: version, cost, the salt and the digest, all in one 60-character string that any bcrypt library can check.
- Verify reads the version, cost and salt from the hash you paste, hashes the password with them, and compares the results. Hashes marked $2a$, $2b$ and $2y$ are understood.
Questions
Which cost should I choose?
Pick the highest cost your server can afford on every login, typically 10 to 12 today. Each step up doubles the time. This tool offers 4 to 15 for hashing and checks hashes up to cost 16, since higher costs take minutes in a browser.
Why does the same password give a different hash each time?
Every hash gets its own random salt, stored inside the hash itself. That is what stops two users with the same password from having the same hash. Any of the hashes verifies against the password.
Is there a limit on password length?
Bcrypt reads only the first 72 bytes of a password. Characters beyond that, or fewer characters if they are accented letters or emoji that take several bytes each, make no difference. The tool warns you when a password is that long.
Is my password sent anywhere?
No. The hashing runs entirely in this page, in a background thread, and nothing you type leaves your device or is saved.
Everything you enter here is processed in this browser tab. Nothing is uploaded, logged or shared. How privacy works here.