← Back to section · Digital Security

ECH: Putting Encryption on the Handshake's First Sentence Too

TLS 1.3 encrypted the certificate but left SNI in the ClientHello in plaintext — which site you are visiting is still written on the first packet. ECH tries to pull this last piece of plaintext into the encrypted channel.

Published 22 November 2026 · 5 min read · PQ Frontier

ECH: Putting Encryption on the Handshake's First Sentence Too
AI-generated site artwork
Video explainer · TLS & HTTPS: One Secure Handshake

The Last Piece of Plaintext: SNI

The first packet of a TLS handshake, the ClientHello, contains an awkward field: SNI (Server Name Indication). When one server IP hosts hundreds or thousands of sites, the server needs SNI to know which certificate to present, so the client must state the domain it wants in plaintext, before any encryption exists. The result: although TLS 1.3 encrypts the certificates, an onlooker glances at SNI, combines it with the destination IP, and still knows with good accuracy “which website you are visiting” — the content is encrypted, the itinerary is not.

For years this was accepted as an engineering necessity: the name had to be spoken before the keys. ECH (Encrypted Client Hello) exists to change that ordering. It is advancing through the IETF as a draft, and mainstream browsers and large CDNs are already deploying and trialing it.

How the Two-Layer ClientHello Works

ECH’s approach is to split one greeting into two layers. The client first looks up the target service’s published ECH configuration through DNS HTTPS resource records (SVCB/HTTPS records), which contain a public key and a “public name.” The real ClientHello (the inner one) holds the true SNI and the full set of extensions; the client encrypts it wholesale with that public key (via HPKE encryption) and tucks it into an extension of an outer ClientHello. The outer layer carries only the public name and looks like a visit to that fronting site.

On the server side, the party that can open the inner layer is whoever holds the matching private key (typically the CDN or reverse-proxy layer): once opened, the handshake proceeds normally against the true SNI. If it cannot be opened, or the client does not actually support ECH, the outer connection is handled as an ordinary one, with the fronting site as the fallback. There is also a crucial anti-downgrade design: the server returns an ECH acceptance signal inside the encrypted part of the handshake, and the client uses it to confirm ECH genuinely took effect. If a man in the middle strips the ECH extension and downgrades the connection to plaintext SNI, the client can detect this after the handshake and refuse — otherwise ECH would be a decoration that can be switched off with one snip.

The Anonymity Set: ECH’s Real Strength Variable

ECH encrypts “the name,” but observers can still see the destination IP. If an IP hosts exactly one site, encrypting SNI changes nothing — the IP is itself the answer. ECH’s protection comes from the anonymity set: the more sites hidden behind the same set of server IPs and the same public name, the more candidates an observer faces for any given connection, and the harder it becomes to pin down “which site was visited.” This is why real-world ECH deployment concentrates on large CDNs: behind one public name sit enormous numbers of sites, so the anonymity set is naturally huge. A self-hosted small site, by contrast, gains next to nothing from enabling ECH behind a dedicated IP.

By the same logic, ECH configurations should be as uniform as possible: if every site publishes distinguishable ECH parameters, observers can match connections by fingerprint again. Deployment guidance therefore recommends that sites under one provider share configurations and public names, pressing distinguishability to a minimum.

The Predecessor ESNI: Why the First Version Did Not Make It

ECH is not the first attempt. Its predecessor ESNI (Encrypted SNI) had a similar idea — encrypt SNI with a key the server publishes via DNS — but deployment exposed several structural problems: the key records lived in DNS TXT records, where updates and consistency were hard to guarantee; clients could not reliably confirm that the server had actually accepted ESNI, and a man in the middle stripping the encryption was hard to detect; and when a server rotated its keys, clients holding stale configurations had no formal retry channel and could only fail or fall back to plaintext. ECH is therefore a redesign rather than a patch: key distribution moved to structured HTTPS resource records, encryption switched to standardized HPKE, the server returns an encrypted acceptance signal in the handshake, and a “retry configuration” mechanism is defined — the server can hand the client fresh configuration inside the handshake, and the next connection uses it automatically. Understanding ESNI’s lessons is what makes each of ECH’s design details legible.

The Companion Relationship with Encrypted DNS

ECH also hides a prerequisite dependency: ECH configurations are distributed through DNS records. If DNS queries themselves are plaintext (the traditional port 53), an observer cannot see the SNI but can infer your intent from which domain’s HTTPS record you looked up — the gap has merely moved house. For ECH to genuinely work, it must be paired with encrypted DNS (DoH or DoT): DNS queries travel in an encrypted channel, fetching the ECH keys leaves no trace, SNI then enters the encrypted channel, and the metadata chain is finally closed. Browser vendors’ rollout order follows exactly this: DoH first, then ECH — only together do the two form complete metadata privacy.

Deployment status, stated qualitatively: ECH is advancing infrastructure-first, sites following. Large CDNs and public DNS providers lay down the server and resolver sides first, browsers then enable it by default in stages, and the cost for an individual site drops close to zero — it is enough for the site to be hosted behind an ECH-supporting provider with its HTTPS records published correctly. Self-hosted sites must track their server software’s support on their own. ECH’s specification text is still at draft stage in the IETF, and details (individual fields of the configuration format) may still be adjusted before finalization — one reason some self-hosted deployments choose to wait and watch.

Expectations also need a line drawn under them: ECH defends against passive observation on the network path and coarse SNI-based filtering. It does not defend against timing and volume analysis of traffic, and it cannot change the fact that “the server and the CDN know who you visited anyway.” Its position is to narrow “everyone along the path can see” down to “only the communicating peer can see” — a real step in privacy engineering, but not an invisibility cloak.

Summary

ECH patches the last piece of plaintext TLS 1.3 left behind: SNI. Mechanically it is a two-layer ClientHello plus DNS-distributed public keys; in strength it depends on the size of the anonymity set behind the public name; in completeness it must be paired with encrypted DNS and backstopped by the anti-downgrade signal. For deployers, joining an ECH-capable CDN and keeping configurations uniform is enough. For a self-hosted small site, do the anonymity-set accounting first, then decide whether the investment is worth it.

Tags: ECHSNIMetadata Privacy