How DNS Works: The Internet's Phone Book Explained
DNS (Domain Name System) translates human names like google.com into IP addresses computers can route to. When you type a name, your device asks a chain of DNS servers — resolver, root, TLD, then the authoritative server — until it gets the IP, usually in milliseconds.
The DNS resolution steps
- Your device checks its local cache; if missing, it asks the configured recursive resolver (often your ISP or 8.8.8.8).
- The resolver asks a root server, which points to the TLD server (.com).
- The TLD server points to the domain's authoritative server.
- The authoritative server returns the IP; the resolver caches it and hands it back.
Common DNS record types
| Record | Purpose |
|---|---|
| A | Name → IPv4 address |
| AAAA | Name → IPv6 address |
| CNAME | Alias to another name |
| MX | Mail server for the domain |
| PTR | Reverse: IP → name |
Frequently asked questions
What does DNS do?
DNS translates domain names (like example.com) into IP addresses so devices can locate and connect to each other.
What is the difference between an A record and a CNAME?
An A record maps a name directly to an IPv4 address; a CNAME maps a name to another name (an alias), which then resolves to an address.
What port does DNS use?
DNS uses port 53 — UDP for most lookups, and TCP for larger responses such as zone transfers.
Related articles
Want hands-on training?
Learn this on real Cisco lab devices with placement support at Attila Technologies, Ahmedabad.