Skip to content
Cloudflare Docs

Delegate subdomains

Subdomain delegation allows different individuals, teams, or organizations to manage different subdomains of a site.

For instance, consider example.com as a Cloudflare domain with www.example.com managed in Cloudflare's DNS app and blog.example.com delegated to nameservers outside of Cloudflare. In this example, blog.example.com can now be managed by individuals who do not have access to Cloudflare credentials for the example.com domain.

Availability

Free Pro Business Enterprise

Availability

Yes

Yes

Yes

Yes


Delegate a subdomain (outgoing)

To delegate a subdomain such as blog.example.com, tell DNS resolvers where to find the zone file:

  1. Log in to the Cloudflare dashboard and select your account.

  2. Select the domain that contains the subdomain to be delegated.

  3. Go to the DNS Records page.

    Go to Records
  4. Create NS records for the subdomain. For example:

    • blog.example.com NS ns1.externalhost.com
    • blog.example.com NS ns2.externalhost.com
    • blog.example.com NS ns3.externalhost.com
  5. (Optional) If the delegated nameserver has DNSSEC enabled, add the DS record in Cloudflare.

Limits

When creating NS records, there are limits on the number of nameservers that can be associated with a single delegation name.

According to DNS standards defined in RFC 1912, a delegation should not include more than seven nameserver names for the same delegation name.

To align with these standards and maintain platform stability:

  • Cloudflare supports up to 10 NS records per delegation name, but the best practice is to keep the set at seven or fewer.
  • Creating more than 10 NS records for the same name is not supported. Requests that exceed this limit may be rejected or fail validation.

Example

DNS management for example.com:

TypeNameContent
NSblogns1.externalhost.com
NSblogns2.externalhost.com
NSblogns3.externalhost.com
NSblogns4.externalhost.com
NSblogns5.externalhost.com
NSblogns6.externalhost.com
NSblogns7.externalhost.com
NSblogns8.externalhost.com
NSblogns9.externalhost.com
NSblogns10.externalhost.com

In this example, Cloudflare would prevent you from adding another NS record for the delegation name blog.

Delegate a subdomain (incoming)

To delegate a subdomain from an external DNS provider to Cloudflare, refer to subdomain setups.