SharkDNS guide
5 min read

EDNS Client Subnet explained

How ECS lets resolvers share client location hints, why GeoDNS depends on it, and how to test it.

EDNS client subnetECS testGeoDNSCDN steering

When to use it

Test ECS when users in different regions report different site versions, when configuring GeoDNS or CDN steering, or when debugging why a resolver returns an unexpected edge location.

How ECS works

A resolver attaches the leading bits of the client IP (for example 8.8.8.0/24) to the query it sends to the authoritative server. The server can then answer with the closest endpoint and echoes back the scope prefix it actually used.

Privacy trade-offs

ECS reveals part of the client network to authoritative servers. Some resolvers like Quad9 deliberately strip ECS for privacy, which can result in less localized answers for GeoDNS domains.