Improving authoritative DNS with the official release of Foundation DNS

Foundation DNS is now officially released. The offering introduces new advanced nameservers, additional resilience and advanced analytics aimed at enterprise requirements. Cloudflare describes it as one of the largest steps forward for its authoritative DNS offering since that service launched in 2010.

Every new enterprise contract that includes authoritative DNS gets the Foundation DNS feature set from today. Existing enterprise customers will receive the features over the course of this year, and those who want them sooner can ask their account team to enable them.

The role of DNS in reachability

DNS is what makes the Internet usable from an end user's perspective. It maps hostnames such as www.cloudflare.com to the IP addresses that browsers, applications and devices dial. Without it, users would have to memorize addresses such as 108.162.193.147 or 2606:4700:58::adf5:3b93 instead of a hostname. Every end user application — social media, banking, healthcare portals — depends on DNS.

For a business, DNS is the first step in reaching a site or connecting to an application: a device has to know where to connect before it can access services, authenticate users or retrieve information. How quickly queries resolve shapes whether an application feels responsive, which has a direct effect on user experience.

When resolution fails

BLOG-2097 Embedded Image - gzSayT

DNS outages are visible immediately. The 2016 Dyn outage, which took down multiple popular ecommerce sites among others, is one illustration; a customer-facing site that cannot be reached costs a business sales directly. DNS tends to be taken for granted until it stops working.

Why a new architecture

Cloudflare has run authoritative DNS for more than a decade and hosts millions of domains across many top level domains (TLDs). Its customer base ranges from single domains holding a handful of records to deployments with tens of millions of records spread over multiple domains. Enterprise customers expect the highest levels of performance, reliability, security and flexibility, plus detailed analytics. Cloudflare identified room for improvement in several of those areas and reworked its DNS architecture, combining new features with structural changes under the Foundation DNS name.

With Foundation DNS, Cloudflare is introducing a set of changes aimed at the reliability, security, flexibility and analytics of its enterprise authoritative DNS service. The core pieces: advanced nameservers, zone-level DNS settings exposed through the API and dashboard, per-account and per-zone DNSSEC keys, a GraphQL-based DNS analytics dataset, a two-week soak period before upgrades, and revised quotas.

Advanced nameservers and the limits of a single Anycast group

Standard authoritative nameservers ship as a pair per zone and use names within the cloudflare.com domain:

$ dig mycoolwebpage.xyz ns +noall +answer 
mycoolwebpage.xyz.	86400	IN	NS	kelly.ns.cloudflare.com.
mycoolwebpage.xyz.	86400	IN	NS	christian.ns.cloudflare.com.

The same zone on Foundation DNS advanced nameservers returns:

$ dig mycoolwebpage.xyz ns +noall +answer 
mycoolwebpage.xyz.	86400	IN	NS	blue.foundationdns.com.
mycoolwebpage.xyz.	86400	IN	NS	blue.foundationdns.net.
mycoolwebpage.xyz.	86400	IN	NS	blue.foundationdns.org.

Two things change here. First, the Foundation DNS servers span multiple TLDs, which shields zones from large-scale DNS outages and DDoS attacks that could affect infrastructure further up the tree, including TLD nameservers. Second, there is an extra nameserver listed — but that alone is not the improvement. Resolvers generally ignore the names and keep only an unordered list of IP addresses per domain. Standard nameservers yield six addresses:

$ dig kelly.ns.cloudflare.com. +noall +answer
kelly.ns.cloudflare.com. 86353  IN      A       108.162.194.91
kelly.ns.cloudflare.com. 86353  IN      A       162.159.38.91
kelly.ns.cloudflare.com. 86353  IN      A       172.64.34.91

$ dig christian.ns.cloudflare.com. +noall +answer
christian.ns.cloudflare.com. 86353 IN   A       108.162.195.247
christian.ns.cloudflare.com. 86353 IN   A       162.159.44.247
christian.ns.cloudflare.com. 86353 IN   A       172.64.35.247

Foundation DNS yields three, because each authoritative nameserver resolves to the same address:

$ dig blue.foundationdns.com. +noall +answer
blue.foundationdns.com. 300     IN      A       108.162.198.1
blue.foundationdns.com. 300     IN      A       162.159.60.1
blue.foundationdns.com. 300     IN      A       172.64.40.1

$ dig blue.foundationdns.net. +noall +answer
blue.foundationdns.net. 300     IN      A       108.162.198.1
blue.foundationdns.net. 300     IN      A       162.159.60.1
blue.foundationdns.net. 300     IN      A       172.64.40.1

$ dig blue.foundationdns.org. +noall +answer
blue.foundationdns.org. 300     IN      A       108.162.198.1
blue.foundationdns.org. 300     IN      A       162.159.60.1
blue.foundationdns.org. 300     IN      A       172.64.40.1

Six versus three is not a downgrade. All standard nameserver addresses are advertised from every Cloudflare data center by a single Anycast group. A hostname.bind TXT lookup against those six addresses from near London returns LHR for all of them, so a London resolver querying any nameserver always lands in the same physical facility.

$ dig @108.162.194.91 ch txt hostname.bind +short
"LHR"

$ dig @162.159.38.91 ch txt hostname.bind +short
"LHR"

$ dig @172.64.34.91 ch txt hostname.bind +short
"LHR"

$ dig @108.162.195.247 ch txt hostname.bind +short
"LHR"

$ dig @162.159.44.247 ch txt hostname.bind +short
"LHR"

$ dig @172.64.35.247 ch txt hostname.bind +short
"LHR"
BLOG-2097 Embedded Image - ClrxIO

Anycast already handles a complete data center failure: traffic for LHR would shift elsewhere. The gap is a data center that is online but unable to answer DNS queries. In that case the resolver has no alternative, and once cached responses expire the domain eventually stops resolving — a hundred IP addresses would not help.

Two Anycast groups

Foundation DNS uses two Anycast groups, breaking the assumption that every authoritative IP is advertised from every data center, so the servers occupy different physical locations from one another.

BLOG-2097 Embedded Image - VlrtDu

Repeating the location check for the Foundation DNS case, one of the three addresses is served from Manchester (MAN):

$ dig @108.162.198.1 ch txt hostname.bind +short
"LHR"

$ dig @162.159.60.1 ch txt hostname.bind +short
"LHR"

$ dig @172.64.40.1 ch txt hostname.bind +short
"MAN"

In cities where Cloudflare operates multiple data centers, all three queries can return the same airport code. At least one address is guaranteed to be advertised from a different data center; otherwise a further query distinguishes them:

$ dig @108.162.198.1 +nsid | grep NSID:
; NSID: 39 34 6d 33 39 ("94m39")

In the returned 94m30, the number before the m identifies the data center that answered; a differing number across the three responses confirms the split. Resolvers monitor all authoritative nameservers for a domain but favor whichever answers fastest, so if one location fails, queries go to the second data center and resolve normally.

BLOG-2097 Embedded Image - VLDGDT
BLOG-2097 Embedded Image - iFBqeh

Advanced nameservers can be enabled today on existing zones, and no cutover or downtime is required: after they are enabled, the previous standard nameservers keep answering queries for the zone.

Zone-level DNS settings

Settings such as secondary DNS overrides previously had to be changed by an account team on request. The most commonly requested options are now configurable per zone in the API and dashboard. Enterprise customers can set:

Setting Zone Type Description
Foundation DNS advanced nameservers Primary and secondary zones Allows you to enable advanced nameservers on your zone.
Secondary DNS override Secondary zones Allows you to enable Secondary DNS Override on your zone in order to proxy HTTP/S traffic through Cloudflare.
Multi-provider DNS Primary and secondary zones Allows you to have multiple authoritative DNS providers while using Cloudflare as a primary nameserver.

DNSSEC keys per account and per zone

DNSSEC lets a resolver verify that a response is authentic and unmodified, preventing cache poisoning and spoofing. Since Universal DNSSEC launched in 2015, Cloudflare has added pre-signed DNSSEC for secondary zones and multi-signer DNSSEC. Records are signed on the fly (live signing), which keeps DNSSEC working with dynamically allocated addresses for proxied origins and with steering-based load balancing.

Cloudflare uses ECDSA P-256, stronger than most RSA keys in use today and cheaper in CPU terms, which matters for on-the-fly signing. DNSSEC normally involves a Zone Signing Key (ZSK) for the records served in responses and a Key Signing Key (KSK) that signs the DNSKEYs, including the ZSK. Today a single ZSK and KSK are shared globally, and because the algorithm is strong, Cloudflare does not see a security need to rotate them. Some customers' policies still require rotation at set intervals, so the advanced nameservers can rotate both keys per account or per zone, first via the API and later in the dashboard.

GraphQL DNS analytics

GraphQL is a query language for APIs and a runtime for executing those queries; clients request exactly the fields they need, combine sources in one call and get real-time updates via subscriptions. Cloudflare's GraphQL API gains a DNS dataset available only with advanced nameservers. It can fetch information about the queries a zone received and replaces the DNS Analytics API for this purpose: large time ranges are queryable quickly without hitting limits or timeouts, the accepted queries are more flexible and more fields are exposed.

One example groups mean and 90th percentile processing time by source IP in 15-minute buckets, useful for seeing which IPs query your records most often in a range:

{
  "query": "{
    viewer {
      zones(filter: { zoneTag: $zoneTag }) {
        dnsAnalyticsAdaptiveGroups(
          filter: $filter
          limit: 10
          orderBy: [datetime_ASC]
        ) {
          avg {
            processingTimeUs
          }
          quantiles {
            processingTimeUsP90
          }
          dimensions {
            datetimeFifteenMinutes
            sourceIP
          }
        }
      }
    }
  }",
  "variables": {
    "zoneTag": "<zone-tag>",
    "filter": {
      "datetime_geq": "2024-05-01T00:00:00Z",
      "datetime_leq": "2024-06-01T00:00:00Z"
    }
  }
}

The sourceIP field is new and enables filtering by the client addresses (usually resolvers) making queries. The API also handles far larger time ranges: a zone with heavy query volume was previously limited to a few days, while the GraphQL API covers up to 31 days, with further range and historical-retention enhancements planned.

The same API backs a new DNS analytics section in the dashboard, where customers can track the most queried records, see which data centers answer them, and view query counts.

BLOG-2097 Embedded Image - 1CToXc

Release process and pricing

The Authoritative DNS product is updated roughly once a week, and some issues only appear under the volume and uniqueness of production traffic. Enterprise customers weigh stability above new features, so releases now spend a two-week soak time on standard nameservers before the Foundation DNS advanced nameservers are upgraded. With no issues after two weeks, the upgrade proceeds, protecting advanced nameserver zones from release regressions.

Authoritative DNS pricing has historically depended on monthly queries and domain count. Foundation DNS now includes 10,000 DNS-only domains by default — zones that use no layer 7 services such as CDN, WAF or Bot Management — so most customers pay only for query volume. It also includes 1 million DNS records across all domains in an account. Larger deployments remain supported: the biggest single zone holds over 3.9 million records, and the largest account just under 30 million records across zones.

What's planned next

Foundation DNS is not feature-complete. The next addition on the roadmap is per-record scoped API tokens and user permissions, a capability that has drawn substantial customer demand. The goal is finer-grained control than account-level access allows, so that permissions can be constrained by record type or by subdomain.

Two illustrative cases:

  • By record type: a given account member could be limited to creating and managing TXT and MX records, leaving address records that carry web traffic protected from accidental edits or deletion.
  • By subdomain: permissions could be scoped to specific subdomains, further narrowing what a given user can change.

Availability for enterprise accounts

Foundation DNS is provisioned per account. Existing enterprise customers who want to use it should contact their account team to have it enabled.