NS What is an NS Record?
NS records delegate a DNS zone to authoritative nameservers. Learn about delegation, why two NS records are required, and what changing them means for DNS.
What is an NS record?
An NS (Nameserver) record specifies which DNS servers are authoritative for a zone. When a resolver wants to find the IP address for example.com, it first queries the root nameservers, which point it to the .com top-level domain servers, which in turn look up the NS records for example.com and direct the resolver to your authoritative nameservers.
NS records are set at two levels: by your registrar (delegation from the parent zone) and within your own zone (the authoritative records).
Anatomy of an NS record
example.com. 86400 IN NS ns1.example.com.
example.com. 86400 IN NS ns2.example.com.
| Field | Value | Description |
|---|---|---|
| Name | example.com. | The zone being delegated. |
| TTL | 86400 | NS records typically have a long TTL (24 hours). Changes propagate slowly. |
| Class | IN | Internet class. |
| Type | NS | Record type. |
| Nameserver | ns1.example.com. | Fully-qualified hostname of an authoritative nameserver. Must resolve to an IP. |
Why you need at least two NS records
DNS requires a minimum of two NS records for redundancy. If the only nameserver goes offline, your domain becomes unresolvable — no website, no email, nothing. Two or more nameservers in different locations ensure queries can always be answered.
Most DNS hosting providers give you 2–4 nameservers automatically.
Changing nameservers
When you switch DNS providers, you update the NS records at your domain registrar (not at the old DNS provider). This starts the delegation process. Because the old NS records are cached by resolvers worldwide, propagation can take 24–48 hours, though in practice it's often faster.
During propagation, some users will be served by the old nameservers and some by the new ones. Keep your records consistent across old and new providers during this window.
Subdomain delegation
NS records can also delegate a subdomain to a different set of nameservers. For example, a company might delegate eu.example.com to a separate DNS zone managed by a regional team:
eu.example.com. IN NS ns1.eu-dns-provider.com.
eu.example.com. IN NS ns2.eu-dns-provider.com.
Frequently asked questions
Can I point an NS record to an IP address?
No. NS records must point to a hostname, which then resolves to an IP via A/AAAA records.
What is the difference between NS records at the registrar and in my DNS zone?
Your registrar holds the delegation NS records in the parent zone (.com, .io, etc.). These tell the internet which servers are authoritative for your domain. Your DNS provider also puts NS records in your zone — these are the authoritative records. Both sets should match.
Why do NS records have long TTLs?
NS records change rarely and resolvers should cache them for a long time to reduce load on root and TLD servers. A 24-hour TTL (86400 seconds) is standard.