TLS & PKI

What is SNI?

Also known as: Server Name Indication

Definition

Server Name Indication (SNI) is a TLS extension that lets a client specify the hostname it is connecting to, allowing the server to present the correct certificate for multi-domain virtual hosting.

SNI (Server Name Indication) is an extension to the Transport Layer Security (TLS) protocol, defined in RFC 6066. In a standard TLS handshake, the client connects to an IP address and the server responds with its certificate. Without SNI, a server hosting multiple domains on the same IP address could not know which domain the client wanted until after the TLS session was established. The handshake would fail, or the server would serve a default certificate that might not match the requested hostname.

SNI solves this by having the client include the target hostname as part of the ClientHello message during the TLS handshake. The server reads this name and selects the matching certificate from its pool. The extension is handled entirely before any application data is exchanged, so it does not break the encryption layer. It works with TLS 1.0, 1.1, 1.2, and 1.3. Almost all modern browsers and servers support SNI. Some older clients, particularly legacy Java applications and Windows XP systems, lack SNI support and must connect to a dedicated IP address.

SNI is essential for shared hosting environments and content delivery networks (CDNs), where a single server IP handles traffic for thousands of different websites. It is a foundational mechanism for modern HTTPS virtual hosting. However, SNI transmits the hostname in plaintext, so a passive network observer can see which site a user is visiting, even if the traffic is encrypted. Encrypted Client Hello (ECH), formerly Encrypted SNI (ESNI), addresses this limitation by encrypting the SNI extension itself.

Key facts

  • Defined in RFC 6066, requires TLS 1.0 or later.
  • Client sends hostname in the ClientHello handshake message.
  • Allows multiple TLS certificates per IP address (virtual hosting).
  • Hostname is transmitted in plaintext; ECH encrypts it.
  • Supported by all major browsers and web servers since roughly 2010.

How it works in practice

A visitor opens https://www.example.com in a browser. The browser resolves the hostname to 203.0.113.1, a shared IP on a CDN. During the TLS handshake, the browser sends an SNI extension containing "www.example.com". The CDN edge server reads the extension, selects the certificate for example.com, and completes the handshake. Without SNI, the CDN would have to assign a dedicated IP per customer, wasting scarce IPv4 addresses.

Related terms

Transport Layer Security TLS handshake Encrypted Client Hello virtual hosting ClientHello certificate HTTPS

References

More in TLS & PKI

ACME Protocol

ACME (Automated Certificate Management Environment) is a protocol that automates the issuance, renewal, and revocation of TLS certificates, defined in RFC 8555.

Certificate Authority

A Certificate Authority (CA) is a trusted entity that issues digital certificates after verifying that the requester controls the domain or identity named in the certificate.

Certificate Chain

A certificate chain is an ordered list of certificates, starting with the server certificate and ending with a root CA, that a client validates to establish trust in the server's identity.

Certificate Pinning

A security technique where an application trusts only a specific, pre-selected certificate or public key for a given server, bypassing the standard chain of trust.

Cipher Suite

A cipher suite is a named set of cryptographic algorithms negotiated during a TLS handshake, specifying key exchange, authentication, encryption, and integrity protection for secure communications.

Domain Validation

Domain Validation (DV) is the lowest level of certificate validation used in TLS/SSL, where the certificate authority verifies only that the applicant controls the domain name, typically via an HTTP or DNS challenge.

ECH

Encrypted Client Hello (ECH) is a TLS extension that encrypts the Client Hello message, including the Server Name Indication (SNI), to prevent on-path observers from learning the target hostname during the handshake.

Extended Validation

Extended Validation (EV) is the highest level of TLS certificate assurance, requiring the certificate authority to perform rigorous, human-verified checks on the legal identity and operational existence of the requesting organization before issuance.

HSTS

HTTP Strict Transport Security (HSTS) is a web security policy mechanism that forces browsers to interact with a website only over HTTPS, preventing downgrade attacks and cookie hijacking.

Intermediate Certificate

An intermediate certificate is a subordinate CA certificate signed by a root CA, used to sign end-entity certificates and enable path validation while the root remains offline.

Who Is Online

In total there are 71 users online: 0 registered, 64 guests and 7 bots.

Most users ever online was 5,555 on 17 Jul 2026, 3:23 am.

Bots: AhrefsBot Applebot Baiduspider Bingbot Other Bot PetalBot SemrushBot

Users active in the past 15 minutes. Total registered members: 369