Pcornel
Browse topics
Options
Recent
Favorites
Security · Technical reference

ChaCha20

Direct answer

ChaCha20 is a fast stream cipher, usually paired with Poly1305 for authentication (ChaCha20-Poly1305). It is used in TLS 1.3, WireGuard and SSH, especially on devices without AES hardware.

When to use this

Use this when ChaCha20-Poly1305 is chosen.

First 30 seconds

1. ChaCha20-Poly1305: AEAD stream cipher, fast without AES hardware.

2. Used in TLS 1.3, WireGuard, SSH.

3. Unique 96-bit nonce (XChaCha20 for random nonces).

4. Constant-time in software.

5. Good mobile/IoT choice.

Operational verification

key + nonce → ChaCha20 stream + Poly1305 tag

Context & applicabilityCommon mistakes · platform/version boundaries
Platform / version applicability
Cryptography, PKI and secrets
applies
Structured applicability is explicit Topic metadata; it does not infer compatibility beyond the stored rows.
At a glance

Operational reference

Fast context before you go deeper.

PlatformCryptography, PKI and secrets
Scope / prerequisiteUse this when ChaCha20-Poly1305 is chosen.
What next?3 suggested next steps
Evidence1
On this pageJump to a specific section
Operational workflow

Verification & Troubleshooting

Start with the observed symptom, prove the nearest boundary, and move outward only when the current state is understood.

1 steps Observe → verify → isolate → change minimally → repeat the original test.
ObservedRecord what the original test actually shows

Capture the concrete output, symptom, packet, log or counter before changing anything.

Step 1 Common mistakes Narrow the fault
  • Reusing nonces with ChaCha20-Poly1305.
Evidence references

Evidence · 1 on this Topic

Expected observations and documentation recipes are reference material. Record actual output, device identity, scope and time before claiming a verified result.

observation · 1
Key points
  • ChaCha20-Poly1305 is fast without AES hardware.
  • It is used in TLS 1.3, WireGuard and SSH.
  • Never reuse a nonce with the same key.
Key checks
  • openssl speed -evp chacha20-poly1305 — performance
  • openssl s_client -connect <host>:443 -ciphersuites TLS_CHACHA20_POLY1305_SHA256 </dev/null — TLS 1.3 test
  • wg show — WireGuard uses ChaCha20-Poly1305
ReferenceWhy it matters1 section · depth on demand

Where it is used

ChaCha20-Poly1305 is an AEAD cipher that is fast in software, so it suits phones and CPUs without AES-NI. It is in TLS 1.3, WireGuard, OpenSSH and QUIC. Like GCM, a nonce must never repeat for the same key.

ReferenceImportant terms & boundaries2 sections · depth on demand

In depth

ChaCha20 is a modern stream cipher designed by Daniel J. Bernstein, almost always used as ChaCha20-Poly1305 authenticated encryption. It is fast in software on devices without AES hardware acceleration — older phones, embedded systems — and resistant to timing attacks by design.

Where it is used: TLS 1.3 and 1.2 cipher suites, WireGuard (exclusively), SSH (chacha20-poly1305@openssh.com), and some disk/file encryption tools. Servers usually offer both AES-GCM and ChaCha20-Poly1305 and let clients without AES acceleration choose ChaCha20.

As with all stream ciphers, a nonce must never be reused with the same key.

ChaCha20-Poly1305 vs AES-GCM

ChaCha20-Poly1305AES-GCM
Speed with AES-NISlowerFaster
Speed without AES hardwareFasterSlow
Side channels in softwareResistantNeeds constant-time implementation
Nonce96-bit (XChaCha: 192-bit)96-bit

Both are fine; servers often prefer AES-GCM and let mobile clients choose ChaCha20.

Source basisSource attribution states what this section is based on; it is not independent proof that the current environment matches it.
ReferenceConfiguration & state1 section · depth on demand

Configuration examples

# OpenSSH (default list already prefers it)
Ciphers chacha20-poly1305@openssh.com,aes256-gcm@openssh.com,aes128-gcm@openssh.com
# WireGuard uses ChaCha20-Poly1305 only

Documented example, not captured output. TLS 1.3 suite: TLS_CHACHA20_POLY1305_SHA256.

Additional reference context Scope · expected state · examples · history · terminology Open only when you need the supporting context
Technical verification history

Verification history & basis

When and against what this Topic was checked. Later text edits do not count as a new check.

2026-09-14 · vendor docCryptography, PKI and secrets current

Authoritative/upstream documentation reviewed for bounded claims in Symmetric Cryptography → ChaCha20. Documentation verification only; this is not observed lab or production Evidence.

Basis: https://csrc.nist.gov/pubs/fips/197/final · confidence 94%
Confirmation

Confirm action

Continue?