ChaCha20 Encryption

Encrypt text, files, or URL content online with ChaCha20 or XChaCha20 using a 256-bit key, nonce, optional counter, and PBKDF2, EvpKDF, or HKDF key derivation. Read more

ChaCha20 encryption online

ChaCha20 is a stream cipher defined in RFC 8439. This tool also supports XChaCha20 with a 192-bit nonce. Both variants use a 256-bit key and XOR plaintext with a generated keystream.

Use this page for interoperability testing, RFC vectors, or recovering data that already uses ChaCha20. For authenticated encryption, prefer ChaCha20-Poly1305 encryption or AES-GCM.

How to use this tool

Choose text, a local file, or URL content and its encoding. Select ChaCha20 or XChaCha20, then enter a 256-bit key and matching nonce, or configure PBKDF2, EvpKDF, or HKDF. Set Counter when the peer implementation starts at a non-zero block counter. Copy or download the Hex or Base64 ciphertext.

Matching cipher parameters

The algorithm, key or KDF settings, nonce, and counter must match ChaCha20 decryption. ChaCha20 uses a 96-bit nonce; XChaCha20 uses a 192-bit nonce. Never reuse the same key and nonce for different plaintexts.

Security warning

Raw ChaCha20 provides confidentiality only and no authentication tag. Prefer ChaCha20-Poly1305 or AES-GCM when integrity matters. Avoid processing production secrets on an untrusted device or browser.

Frequently asked questions

Why can I not decrypt the result elsewhere?

Compare the algorithm, key bytes or KDF parameters, nonce length and value, counter, plaintext encoding, and ciphertext encoding.

Does encryption detect tampering?

No. Use ChaCha20-Poly1305 encryption when you need an authentication tag.

Input
Output
Share Link
Settings
Nonce