FAQ Domains & DNS

What are nameservers?

They decide who gets to answer questions about your domain — and changing them hands your whole domain to a different company.

Updated 4 min read Beginner

Nameservers are the servers that hold the authoritative answer to "where does this domain point?" Every domain names two or more of them, and whichever ones it names are the only machines on the internet whose answers about that domain count.

They look like hostnames, because that is what they are:

ns1.example-host.com
ns2.example-host.com

What they actually do

When somebody types your domain into a browser, their computer has to turn that name into a server address. It asks the internet's root servers, which say "for .com, ask the .com registry". The registry says "for this domain, ask these nameservers". And those nameservers give the final answer: this is the IP address of the website, this is where the email goes, and so on.

The registry only stores which nameservers to ask. It does not store your records. That distinction explains almost every confusing thing about DNS.

Why it matters which ones you use

Because the nameservers hold your records, whoever runs them controls your domain's DNS — and the panel where you edit those records lives with them too.

If your nameservers are…Then you edit DNS records…
your hosting provider'sin your hosting control panel
your registrar'sat the registrar, where you bought the domain
a third party's (a CDN, a DNS service)in that service's dashboard
This is the single most common DNS mistake

Editing records in the wrong place. If your domain uses your host's nameservers, records you carefully change at the registrar are simply never consulted — the registrar's DNS panel is still there, still editable, and completely ignored. Nothing warns you. Find out which nameservers the domain actually uses before you edit anything.

How to see which ones a domain is using

dig +short NS yourdomain.com
nslookup -type=ns yourdomain.com    # Windows

Whatever comes back is authoritative for that domain right now, regardless of what any control panel shows you.

When you need to change them

Rarely, and always deliberately. The usual reasons are moving to a new hosting provider, or moving DNS to a service that offers something your current provider does not. Our guide to pointing a domain at your hosting covers the change step by step.

Two things worth knowing before you do:

  • Changing nameservers moves everything at once — website, email, subdomains, verification records. If any of those currently work, recreate them on the new nameservers before you switch, not after.
  • Replace, never mix. Leaving the old nameservers alongside the new ones means different visitors get different answers depending on which server they happened to ask. The site then appears to work intermittently, which is far harder to diagnose than a site that is plainly down.

Nameservers and the domain registration are separate things

A domain can be registered with one company and use another company's nameservers indefinitely. Changing nameservers does not move the registration, does not affect renewal, and does not change who you pay for the domain. The two are often confused because both are set from the same page at the registrar.

Related reading