Bcrypt Hash Generator
Free online bcrypt hash generator. Hash passwords with configurable cost factor. Includes embedded salt for secure password storage. All processing is local and private.
Enter a password and click "Generate Hash".
How to Use Bcrypt Hash Generator
Enter Password
Type the password you want to hash. The tool never sends your password anywhere — all processing stays in your browser.
Adjust Cost Factor
Set the cost factor (4-12 rounds). Higher = more secure but slower. Cost 10 is the recommended default for production — takes ~100ms to hash on modern hardware.
Copy the Hash
The bcrypt hash includes the salt and cost factor embedded in the output. Copy it and store it in your database for password verification.
Example Output
$2a$10$N9qo8uLOickgx2ZMRZoMyeIjZAgcfl7p92ldGxad68LJZdL17lhWy
| | | |
| | | +-- Hash (31 chars)
| | +-- Salt (22 chars)
| +-- Cost factor (2^10 = 1024 rounds)
+-- Algorithm (2a = bcrypt)Frequently Asked Questions
What is bcrypt?
Bcrypt is a password hashing function designed by Niels Provos and David Mazieres in 1999. It's based on the Blowfish cipher and includes a built-in salt and a configurable cost factor that makes brute-force attacks exponentially slower. Unlike fast hashes (MD5, SHA-256), bcrypt is deliberately slow — this is a feature. A slow hash means an attacker can try fewer passwords per second.
What cost factor should I use?
Cost 10 is the standard for production. It takes ~100ms on modern hardware. Cost 12 takes ~400ms — more secure but adds latency to login. Test on your target hardware: the hash should take 100-300ms. Too fast = vulnerable to brute force. Too slow = bad user experience on login. Never go below cost 8 — it's trivially fast on GPUs.
Why does bcrypt include the salt in the output?
The salt is embedded in the hash output for storage convenience. When verifying a password, you pass the stored hash (which contains the salt) and the candidate password to bcrypt.verify(). Bcrypt extracts the salt from the stored hash, re-hashes the candidate password with that salt, and compares. This means you don't need to store the salt separately.