Back to Tools

Bcrypt Generator

Generate and verify PBKDF2 hash passwords with configurable cost factor. Bcrypt-style security, 100% client-side via Web Crypto API.

12

~4,096 iterations. Default. Good balance for most applications.

About PBKDF2-SHA256

PBKDF2 (Password-Based Key Derivation Function 2) is a NIST-recommended password hashing algorithm. It applies HMAC-SHA256 iteratively to make brute-force attacks computationally expensive.

Higher cost factors increase the number of iterations exponentially (2^rounds), making each hash attempt slower for attackers.

All computation happens in your browser via the Web Crypto API. No data is transmitted.

What is password hashing

Password hashing transforms a plaintext password into a fixed-length string that cannot be reversed. Unlike encryption, hashing is a one-way function: you can verify a password against a hash, but you cannot recover the original password from the hash alone.

Secure hashing algorithms like PBKDF2, bcrypt, and Argon2 are deliberately slow (key stretching), making brute-force attacks computationally expensive. This tool uses PBKDF2-SHA256 via the Web Crypto API built into your browser.

Comparing hash algorithms

AlgorithmTypeGPU resistantUse case
MD5 / SHA-1Fast hashNoChecksums only, never for passwords
SHA-256Fast hashNoData integrity, not password storage
PBKDF2Key derivationPartialPassword storage (NIST recommended)
bcryptPassword hashYesPassword storage (industry standard)
Argon2idMemory-hardYesPassword storage (OWASP preferred)

PBKDF2 rounds and security

The cost factor (number of iterations) controls how slow hashing is. More rounds means more CPU time per hash, slowing down attackers. OWASP recommends at least 600,000 iterations for PBKDF2-SHA256 as of 2024. Each doubling of iterations doubles the attack cost.

This tool lets you configure the round count to test the performance tradeoff between security and user experience. In production, balance iteration count against acceptable login latency (typically under 250ms).

Frequently asked questions

Is my password sent to any server?

No. Hashing is performed entirely in your browser using the Web Crypto API. No data is transmitted over the network.

What is the difference between bcrypt and PBKDF2?

Both are key-stretching algorithms designed for password storage. Bcrypt uses the Blowfish cipher and is inherently GPU-resistant. PBKDF2 uses HMAC-SHA256 and is NIST-approved but less GPU-resistant unless iteration counts are very high. Argon2id is the modern recommended choice.

Can I use the generated hash in my application?

The output format is tool-specific. For production, use your language's crypto library (e.g., Python's hashlib.pbkdf2_hmac, Node's crypto.pbkdf2) to generate hashes with a cryptographically random salt.