DNS Basics

The Domain Name System (DNS) is like the phonebook of the internet. It translates human-readable domain names into IP addresses that computers use to identify each other.

The DNS hierarchy.root.com.org.plexample.comNSexample.orgNS
The root delegates every top-level domain, and each top-level domain delegates the nameservers for a domain.

How DNS Works

When you type a domain name like "example.com" in your browser, your computer needs to find the corresponding IP address. This process involves several steps:

  1. Your computer checks its local DNS cache
  2. If not found, it queries a recursive DNS server
  3. The recursive server queries root servers, then TLD servers, then authoritative servers
  4. The IP address is returned and cached
How a lookup is resolvedClientResolver.root.comNSA93.184.216.341234
A lookup that is not cached asks the root, then the top-level domain, then the domain's own nameservers.

Key DNS Components

  • DNS Resolver - The server that handles your DNS queries
  • Root Servers - The top-level DNS servers that direct queries to TLD servers
  • TLD Servers - Top-level domain servers (.com, .org, .net)
  • Authoritative DNS Servers - The servers that actually contain DNS records

Why DNS Matters

DNS is fundamental to how the internet works. Understanding DNS helps you:

  • Configure your domain's email and website
  • Debug issues with domain resolution
  • Implement security measures like SPF, DKIM, and DMARC
  • Ensure high availability and performance
Try it on your domain

See the theory in practice — run a DNS Lookup for your own domain.