How does a domain name work?

Home / Everything About / Everything About Domains / How does a domain name work?

In the last chapter, we established that a domain name and a website are two different things. A domain name is the address. The website is what lives at that address. The system that connects them is DNS. Now we go deeper into how a domain name works and what is happening every time someone types it into a browser.

The short answer is that a domain name works by translating a human-readable address into the numeric IP address of the server where your website files are stored. The full answer involves a chain of lookups that your browser handles automatically, in fractions of a second, without you ever seeing it happen.

How does a domain name work?

You type wemasy.com into your browser and hit Enter. Here is what happens next, in the order it happens.

Your browser first checks its own cache. If it has looked up this domain name recently, it already knows the IP address and loads the site directly. If not, it passes the request to a DNS resolver. The resolver is usually operated by your internet service provider, though you can also use public resolvers. Its job is to find the IP address for the domain name you requested.

The resolver checks its own cache next. If it has looked up wemasy.com recently, it returns the answer from memory. If not, it starts asking. The resolver sends a query to a root nameserver. Root nameservers sit at the top of the DNS system. They do not know the IP address for every domain name, but they know where to find the right nameservers for each top-level domain. The root nameserver tells the resolver to ask the TLD nameserver for .com.

The TLD nameserver handles all .com domains. It does not know the IP address for wemasy.com specifically, but it knows which nameservers are responsible for it. It sends the resolver to the authoritative nameserver for wemasy.com.

The authoritative nameserver is where the real answer lives. It holds the DNS records for the domain, including an A record that maps the domain name to a specific IP address. The resolver gets that IP address, passes it back to your browser, and your browser connects to the server at that address. The server returns the website files, and the page loads.

From your perspective, you typed a name and a page appeared. Behind that, four separate systems responded in sequence. The whole exchange typically takes under 100 milliseconds.

What is DNS and why does it exist?

DNS stands for Domain Name System. It is the global directory that makes it possible to use names instead of numbers to find websites. Without it, you would need to memorize a string like 185.230.65.11 every time you wanted to visit a site.

The system was built to be decentralized. There is no single server that knows where every website lives. Instead, responsibility is distributed across thousands of nameservers around the world, each holding records for a portion of the total. This makes the system fast, resilient, and scalable.

DNS handles far more than just websites. It routes email, verifies domain ownership, powers subdomains, and handles security records. For the full picture of how the DNS system works at this level, the DNS deep dive chapter covers it in detail.

What are nameservers and what do they do?

A nameserver is a server that stores DNS records for a domain. When you register a domain name, it gets assigned to a set of nameservers. Those nameservers are the authoritative source for everything DNS-related about that domain. If someone wants to know the IP address behind your domain name, they end up at your nameservers for the answer.

Most domain registrars assign default nameservers when you register a domain. If you are using a separate hosting provider, you update your nameservers to point to your host. This is how the domain you registered in one place gets connected to the website you built somewhere else.

When you change nameservers, you are telling the global DNS system to start looking for your domain's records in a new place. Any DNS records you had set up with the old nameservers do not carry over automatically. You recreate them on the new nameservers.

What is an A record?

An A record is a DNS record that maps a domain name to an IP address. It is the core record that makes a domain name point to a website. When the DNS resolver reaches your authoritative nameserver and asks where wemasy.com lives, the A record is what it finds.

There are several types of DNS records, each serving a different purpose. A records handle IP address mapping. MX records handle email routing. CNAME records create aliases that point one domain name to another. TXT records hold verification strings and security configurations. The A record is the one most directly tied to how your domain name loads a website. For a full breakdown of what each type does, see the guide to DNS record types.

What happens when DNS is not set up yet?

If you register a domain name and never configure DNS records, the domain exists in the registry but leads nowhere. A browser that tries to look up the IP address gets no answer. The page does not load. Visitors see an error or a blank screen, depending on the browser.

This is why registering a domain name is not the same as having a working website. The domain name is live in the sense that it is registered and no one else can take it. But it is not functional until the DNS records are set up and pointing to a server with actual website files on it.

The same thing happens temporarily any time you make changes to your DNS settings. There is always a gap between when you save the change and when the change reaches the full DNS system.

What is DNS propagation?

DNS propagation is the time it takes for a change in your DNS records to spread across all the resolvers and caches around the world. When you update an A record or switch nameservers, that change does not take effect everywhere instantly. Different resolvers have cached the old information for different amounts of time.

How long propagation takes depends on a setting called TTL, which stands for time to live. TTL is set on each DNS record and tells resolvers how long to cache the information before checking for an update. A TTL of 3,600 seconds means resolvers may hold onto the old data for up to an hour before refreshing. Lower TTLs mean faster propagation but more frequent lookups.

During propagation, some visitors reach the old server and some reach the new one, depending on which resolver they are using. Full propagation typically completes within a few hours, though it can occasionally take up to 48 hours. The DNS propagation chapter covers this in full, including how to check whether propagation is complete and what to do if it is taking longer than expected.

Why does this process matter for your brand?

Take a closer look at how the domain name system is designed and you will find a level of control that only becomes obvious the first time you need to use it.

Your domain name is not tied to any specific server. It points to whichever server you tell it to. If you move your website to a different host, you update the DNS records and visitors follow. The domain name stays the same. Your brand's address does not change. Your links, your search rankings, and your audience's memory of your address all stay intact.

This separation between the domain and the server is what makes rebuilding or migrating a site manageable. You can build a new version of your site on a staging server, test it, and then update the A record to point your domain name at the new server. The switchover happens without your visitors ever seeing a broken address.

It also means your domain name has a kind of permanence that your website files do not. Servers get upgraded, platforms change, websites get rebuilt. The domain name persists through all of it as long as you keep renewing it. That is why your domain name is a brand asset worth protecting. For more on what a domain name is and what registering one involves, see the chapter on the difference between a domain name and a website.

How WEMASY handles domain name connection

On WEMASY, when you register a domain name and build your website within the same account, the DNS connection is configured automatically. The nameservers, A record, and any other required DNS records are set up for you. You do not need to log into a separate registrar, locate your nameserver settings, or manually enter an IP address.

If you registered your domain name elsewhere and want to use it with a WEMASY site, you connect it by updating the nameservers at your registrar to point to WEMASY's nameservers. After that, WEMASY manages the DNS records for the domain. Details on what each plan includes are at WEMASY pricing.

Frequently asked questions

What happens if I point my domain to the wrong IP address?

Why does my site still show the old version after I moved to a new server?

Can I use the same domain name for two different websites at the same time?

Do I need technical knowledge to manage my domain's DNS settings?

What is the difference between a nameserver and a DNS record?

You now know how a domain name works, from the moment someone types it to the moment the page loads. There is a related term you have probably seen used interchangeably with domain name, but it is a different thing. That term is URL. The next chapter breaks down exactly what separates a URL from a domain name, and why the distinction matters when you are setting up your site.