Argon2 Hash Generator

Generate Argon2id, Argon2i, and Argon2d password hashes in your browser with tunable iterations, memory cost, parallelism, and hash length, and copy the standard PHC-encoded string.

100% private. Hashing runs entirely in your browser using WebAssembly. Your password and salt never leave your device.

Enter the salt as a hexadecimal string of at least 8 bytes, or click Random salt to generate one.


    

The Argon2 Hash Generator creates Argon2id, Argon2i, and Argon2d password hashes right in your browser. Pick the variant, tune the iterations, memory cost, parallelism, and hash length, supply or generate a salt, and get back the standard PHC-encoded hash string ready to store or verify. Everything runs client-side with WebAssembly, so your password and salt never leave your device.

What is Argon2?

Argon2 is a modern, memory-hard password-hashing function and the winner of the 2015 Password Hashing Competition. Because it deliberately uses large amounts of memory and time, it makes large-scale brute-force and GPU or ASIC attacks far more expensive than older hashes like MD5 or SHA-256. It comes in three variants: Argon2id, the recommended default that blends the other two; Argon2i, tuned to resist side-channel attacks; and Argon2d, tuned to resist GPU cracking. This tool outputs the hash in the portable PHC string format that encodes the variant, version, parameters, salt, and digest in a single line.

How to generate an Argon2 hash

Enter your password, choose a variant and parameters, then generate the hash. The result is the encoded PHC string you can copy and store.

  1. Type or paste the password or text you want to hash.
  2. Click Random salt to generate a fresh salt, or paste your own hexadecimal salt of at least 8 bytes.
  3. Choose the variant (Argon2id is recommended) and adjust iterations, memory, parallelism, and hash length.
  4. Click Generate hash and wait while the memory-hard computation runs.
  5. Copy the resulting PHC-encoded hash to store it or verify a password later.

Choosing Argon2 parameters

Argon2 has three cost parameters that control how slow and memory-hungry hashing is. Memory cost (in KiB) is the biggest lever against cracking hardware; common values range from 19456 KiB up to 65536 KiB or more. Iterations (the time cost) multiply the work for a fixed amount of memory. Parallelism sets how many lanes the algorithm uses and is often left at 1 to 4. The OWASP guidance for Argon2id suggests starting around 19 MiB of memory with 2 iterations and a parallelism of 1, then raising the cost until hashing takes a comfortable fraction of a second on your server. Higher values are stronger but slower, so tune them to your hardware.

Why use this Argon2 generator?

  • Fully client-side: hashing runs in your browser with WebAssembly and nothing is uploaded.
  • Supports all three variants: Argon2id, Argon2i, and Argon2d.
  • Tunable iterations, memory cost, parallelism, and hash length.
  • Outputs the standard PHC-encoded string that stores the parameters and salt alongside the digest.
  • Built-in random salt generator using a cryptographically secure source.
  • One-click copy of the final hash.

Frequently asked questions

Is my password sent to a server?

No. The Argon2 computation runs entirely in your browser through a WebAssembly module. Your password, salt, and the resulting hash are never transmitted, stored, or logged. You can confirm this by watching your browser network tools while you generate a hash.

Which Argon2 variant should I choose?

Argon2id is the recommended default for password hashing and is what most guidance, including OWASP, suggests. It combines the side-channel resistance of Argon2i with the GPU-cracking resistance of Argon2d. Choose Argon2i only if you specifically need maximum side-channel resistance, and Argon2d only for use cases without untrusted side-channel exposure.

What is the PHC string the tool outputs?

It is the standard self-describing format for password hashes. A string like $argon2id$v=19$m=65536,t=3,p=1$SALT$HASH records the variant, the Argon2 version, the memory, time, and parallelism parameters, the base64 salt, and the base64 digest. Storing this single string is enough to verify a password later, because every parameter needed is embedded in it.

Why does generating a hash take a moment?

That delay is intentional. Argon2 is a memory-hard function designed to be slow and to consume a lot of memory, which is exactly what makes it resistant to brute-force attacks. Higher memory and iteration values increase the delay. If it feels too slow for testing, lower the memory and iterations; raise them again for production-strength hashes.

Does the salt need to be secret?

No. A salt does not need to be secret, but it should be unique and unpredictable for each password so that identical passwords produce different hashes and precomputed rainbow tables are useless. Use the Random salt button to generate a fresh 16-byte salt, and store it as part of the PHC string.