Argon2 is a password hashing function that won the 2015 Password Hashing Competition. It comes in three variants (Argon2d, Argon2i, Argon2id) with Argon2id being the recommended default. It’s the modern successor to bcrypt.
Hash Format
$argon2id$v=19$m=65536,t=3,p=4$c2FsdC1oZXJlLTE2Yg$hashed-output-here...
argon2id— variantv=19— Argon2 versionm=65536— memory cost in KiB (64 MiB)t=3— time cost (iteration count)p=4— parallelism (threads)- next base64 chunk — salt
- final base64 chunk — the hash
What Makes Argon2 Better than bcrypt
- Memory-hard — an attacker needs both CPU and RAM to run cracking at scale. GPUs have limited RAM per core, making Argon2 more GPU-resistant.
- Tunable dimensions — cost isn’t a single work factor; memory, time, and parallelism can be tuned independently to your infrastructure.
- Modern crypto pedigree — competition-winner, extensively analyzed.
Recommended Parameters (2026)
m=65536(64 MiB),t=3,p=4— safe baseline for interactive loginm=131072(128 MiB),t=4,p=2— hardened, ~500ms per hash
Argon2id vs Argon2d vs Argon2i
- Argon2id — hybrid, resistant to both side-channel and GPU attacks — always use this
- Argon2d — GPU-resistant only
- Argon2i — side-channel resistant only
Generate Argon2 and other password hashes with the hash generator.
Related
Check the bcrypt glossary entry, the SHA-256 entry, and the MD5 entry — the wrong choice for passwords.