Hash a password
bcrypt with a tunable cost factor. A fresh random salt is generated for every hash.
Verify a password
Check a candidate password against an existing bcrypt hash.
The hash or the verification result appears below.
Hash passwords with bcrypt and verify them against existing hashes. Tune the cost factor to match your hardware; verification mode checks a password against a hash.
bcrypt with a tunable cost factor. A fresh random salt is generated for every hash.
Check a candidate password against an existing bcrypt hash.
The hash or the verification result appears below.
bcrypt, designed by Provos and Mazieres in 1999, is built on the Blowfish cipher's expensive key schedule (EksBlowfish). Its cost factor makes hashing deliberately slow, doubling the work with each increment, so hashes stay resistant as hardware improves. The output string embeds the algorithm version, cost and salt, for example $2a$10$....
Cost 10 (1024 iterations) was the old default; modern guidance suggests 12 or higher, targeting roughly 250-500ms per hash on your server. Higher cost means better protection but slower logins, so benchmark on your own hardware. Always use a unique random salt per password, which bcrypt generates automatically.