Hash Lab

Password hashing / KDF

PBKDF2

Password-Based Key Derivation Function 2, specified in PKCS #5 v2.1 (RSA Labs, 2000) and republished as RFC 8018 in 2017. PBKDF2 turns a password into a key by iterating an HMAC chain thousands or millions of times; the only cost lever is iteration count.

At a glance

OutputAny length
Cost parameteriteration count c
Internal primitiveHMAC over a base hash (SHA-256 / SHA-512)
Memory costNone , trivially parallelizable on GPUs
StandardRFC 8018 (PKCS #5 v2.1)
StatusAcceptable for legacy; prefer Argon2id / scrypt for new designs

Recommended iteration counts (2026)

Calibrate so an interactive login takes 100–500 ms on real hardware.

Where it is used

Why it’s no longer the first choice

No memory cost. A modern GPU can attempt millions of PBKDF2-HMAC-SHA-256 candidates per second per device. Memory-hard alternatives like Argon2id force the attacker to commit RAM per candidate, flattening the GPU advantage.

Try it

The KDF Lab includes PBKDF2 with HMAC-SHA-256 or HMAC-SHA-512 selectable and an iteration-count slider.

References

Generate

Run pbkdf2 on your input

16 bytes

600,000

Test Your Knowledge

Quick MCQ check on this algorithm

Start Quiz →

AI Summary

Summarize this page in your favorite LLM