ECS (EDNS Client Subnet)

EDNS Client Subnet (ECS, RFC 7871) is a [[dns|DNS]] extension that allows [[dns-resolver|recursive resolvers]] to include a partial client IP address in queries to [[authoritative-dns|authoritative nameservers]]. This enables CDNs and geolocation-based DNS responses to return servers closest to the end user rather than the resolver. ECS involves a privacy trade-off: it improves content delivery performance but shares partial IP data beyond the resolver.

Example

Google's CDN uses ECS to detect that a user in Tokyo is querying via a US-based resolver, and returns Japanese edge server IPs instead of US ones.