Yiwei Yu

Posted on: 2026-01-05

How DNS Resolution Works: Nameservers and A Records

Let’s start with domain registration.

First, registering a domain and hosting a domain are two different things, and people often mix them up because many companies offer both services together. In most cases, the domain registrar also offers domain hosting, but their responsibilities are completely different.

Domain host

A domain host is responsible for creating 2–4 name servers for your domain. These name servers are actually the “addresses” that point to the domain host service. Then, inside the domain host’s control panel, you link your domain to an IP address, which is called the A record.

Domain registrar

The registrar’s job isn’t just to sell you the domain name. More importantly, it takes the name servers generated by your domain host and submits them to the registry (I’ll explain what a registry is in a minute).

For example, if you register a domain on AWS (AWS acts as the registrar), Amazon’s Route 53 (the domain host) will automatically host it and generate Route 53 name servers for you.

Moving domain host

Let’s say you registered your domain on AWS. By default, your domain host will be Route 53, and Route 53 generates name servers for your domain.

Now one day you decide not to use Route 53 and want to switch to GoDaddy, GoDaddy DNS (their domain hosting service) will generate 4 GoDaddy-specific name servers for your domain. Then, in GoDaddy DNS' panel, you link your domain to an IP address (the A record)

But you’re not done yet. You must go back to AWS (your registrar) and replace the old Route 53 name servers with the new GoDaddy name servers. Then AWS reports the updated name servers to the registry. Usually it takes about – hours for the change to fully propagate and take effect.

One thing to note: you can switch domain hosts pretty easily, but switching registrars is a lot more complicated, and usually not worth it, so most people don’t do it.

So, what exactly are name servers, and what is a registry?

To understand that, we have to start from the DNS root servers.

There are 13 groups of DNS root servers in the world. They store information about who manages each top-level domain (TLD), like .com, .net, .us, jp, etc. Those managers are the registries. The registry then stores the name servers. And those name servers are basically the domain host’s DNS address.

So the chain looks like this:

Root servers → TLD registry → Domain host → IP address

The full DNS resolution process (end to end)

Let’s walk through what happens when you type a domain name in your browser, like yiweiyu.com, and hit Enter.

Your browser first checks its local DNS cache. If it doesn’t find anything, it checks the OS DNS cache, and then the  hosts  file. If none of those have the IP address, your DNS resolver (usually your ISP’s resolver) starts querying outward.

 1. It picks a nearby root server (from those 13 root server groups) and asks: “Who is responsible for .com ?”

 2. The root server replies: “ .com is managed by the registry Verisign,” and returns Verisign’s address.

 3. The resolver goes to Verisign and asks: “For yiweiyu.com, what are the name servers?”

 4. Verisign looks it up and sees that AWS previously submitted name servers generated by Route 53. So Verisign replies: “This domain is using Route 53,” and returns those name server addresses.

 5. The resolver randomly picks one of the name servers(Route 53's address) and asks: “What’s the IP address for yiweiyu.com?”

 6. Route 53 replies with the IP address from the domain’s record.

 7. The resolver caches the result locally, so the next time you visit, it can return the IP quickly without repeating the full process.

And that’s basically the whole DNS resolution process.




Comments (
)
Sign in to comment
0/500
Comment