🌐 WhereIsDNS

Anycast

Anycast is a network routing technique where a single IP address is advertised from many physical locations at once. When a client sends a packet to that IP, BGP routes the packet to whichever location is "closest" by network topology — usually the lowest-latency one.

Anycast in DNS

The big public resolvers all use anycast: 1.1.1.1 (Cloudflare), 8.8.8.8 (Google), 9.9.9.9 (Quad9), 208.67.222.222 (OpenDNS). When you set your DNS resolver to one of those IPs, your queries actually go to whichever data center is geographically nearest you, even though you're typing the same address.

Anycast at the authoritative tier

Authoritative DNS providers also use anycast. Cloudflare DNS, Route 53, NS1, and most modern providers run their nameservers as anycast networks — so a query to ns1.cloudflare.com from Sydney lands in Sydney, while the same query from Madrid lands in Madrid.

Why it matters

Anycast gives you three things: lower latency (closer pop), redundancy (one data center failing means traffic flows to the next nearest), and DDoS resilience (an attack from one region only affects that region's pop).

Anycast vs GeoDNS

These solve different problems. Anycast gives every user the closest copy of the resolver; GeoDNS gives every user a different answer. They're often used together: an anycast nameserver serving GeoDNS-routed records.

Related: GeoDNS · resolver.