Generate cryptographic keys using PBKDF2 (Password-Based Key Derivation Function 2) with salt and iterations.
PBKDF2 (Password-Based Key Derivation Function 2) turns a passphrase into a fixed-length cryptographic key. It works by repeatedly applying a keyed hash (HMAC) over the passphrase and a salt, thousands or hundreds of thousands of times. That deliberate slowness is the point: it makes each guess expensive for an attacker while remaining fast enough for a single legitimate derivation.
This generator runs entirely in your browser. The passphrase and salt you enter are never uploaded, logged, or stored — the key is derived locally with JavaScript and stays on your device. You can choose the salt, the iteration count, the output key length in bits, and the underlying hash function (SHA-256, SHA-384, or SHA-512), then read the result as hexadecimal or Base64.
The salt is not secret — its job is to ensure that the same passphrase produces a different key each time, defeating precomputed rainbow-table attacks — so store it alongside the derived key. Use a large, random salt and as many iterations as your performance budget allows; OWASP currently recommends hundreds of thousands of iterations for SHA-256. PBKDF2 is well suited to deriving encryption keys and verifying passwords, though for new password-storage systems a memory-hard function such as Argon2 or scrypt offers stronger resistance to GPU attacks.
No. The salt only needs to be unique and random, not hidden. Store it alongside the derived key so you can reproduce the same key from the same passphrase later.
Use as many as your performance budget allows. OWASP currently recommends hundreds of thousands of iterations for PBKDF2 with SHA-256; more iterations make brute-force guessing more expensive.
No. The key is derived locally in your browser using JavaScript, so the passphrase and salt never leave your device.
It remains a solid, widely supported standard for key derivation and password verification. For new systems, memory-hard functions such as Argon2 or scrypt resist GPU-based attacks better, but PBKDF2 is a reasonable choice where those are unavailable.
They are two encodings of the same derived key. Hexadecimal is common in many libraries and configs, while Base64 is more compact; pick whichever your target system expects.