💬 qa

What Is DNS? A Plain-English Q&A

Common questions about DNS answered in plain language — recursive vs authoritative servers, TTL and caching, how nameservers work, and why they matter when you visit a URL.

What Is DNS? A Plain-English Q&A

DNS is one of those things you use every time you browse the web — but what *is* it, exactly? Here are common questions about DNS, answered in plain language.


What does DNS do?


DNS (Domain Name System) translates human-friendly domain names like example.com into IP addresses like 93.184.216.34 that computers use to communicate.


Without DNS, you'd need to memorize IP addresses for every site you visit. DNS is the internet's phonebook — you look up a name, and it tells you the number.


Want to see this in action? Check out our interactive lesson on what DNS does.


What's the difference between recursive and authoritative DNS servers?


These are two different jobs in the DNS lookup process:


Authoritative DNS servers are like the official record keepers. If you own example.com, your authoritative nameservers hold the *official* answer for where example.com points. When someone asks "Where is example.com?" these servers give the final answer.


Recursive DNS servers (also called resolvers) are like research assistants. When your browser needs to look up a domain, it asks a recursive server. That server doesn't know the answer yet, so it goes out and asks the authoritative servers on your behalf. Then it brings the answer back to you.


Think of it this way:

  • **Authoritative** = "I own the answer"
  • **Recursive** = "I'll find the answer for you"

  • Your computer typically uses your ISP's recursive server or a public one like 8.8.8.8 (Google) or 1.1.1.1 (Cloudflare). Those recursive servers then hunt down the authoritative servers that actually know the answer.


    What is TTL and why does DNS cache?


    TTL (Time To Live) is how long DNS answers are allowed to be cached before they expire.


    Every DNS record has a TTL value — usually measured in seconds. When a recursive server looks up example.com, it caches the answer for that TTL duration. If someone else asks for example.com within that time, the recursive server can answer immediately from its cache instead of asking the authoritative server again.


    Why caching matters:


  • **Speed**: Cached answers are instant. No need to traverse the DNS hierarchy every time.
  • **Reliability**: If authoritative servers go down, cached records keep sites accessible for a while.
  • **Reduced load**: Authoritative servers don't get hammered with the same queries repeatedly.

  • The downside:


    If you change your DNS records (like pointing example.com to a new IP), the old cached answer sticks around until the TTL expires. That's why DNS changes can take time to "propagate" — it's really caches expiring across the internet.


    Common TTLs:

  • **300 seconds (5 minutes)**: Good for changes you plan to make soon
  • **3600 seconds (1 hour)**: Balanced for most sites
  • **86400 seconds (24 hours)**: For stable records that rarely change

  • Why would empty or missing nameservers break a site?


    Your domain's nameservers are the authoritative servers that hold your DNS records. When you register a domain, you must configure nameservers to tell the internet "these are the servers that know where my domain points."


    If your nameservers are:

  • **Missing** (not configured)
  • **Empty** (configured but pointing to nothing)
  • **Unreachable** (servers are down or misconfigured)

  • ...then recursive servers have nowhere to get answers from. The domain effectively doesn't exist from DNS's perspective.


    What happens:


  • Someone types `yoursite.com` into a browser
  • Their recursive server asks: "Who are the nameservers for yoursite.com?"
  • The answer is empty, broken, or nonexistent
  • The browser shows an error: "DNS_PROBE_FINISHED_NXDOMAIN" or "Server not found"

  • Even if your website is perfectly healthy and running on a server somewhere, if DNS can't resolve the domain, no one can reach it. DNS is the first step in the journey of a URL — if that step fails, nothing else happens.


    How does this all fit together when I visit a URL?


    Let's walk through what happens when you type example.com into your browser:


  • **Browser checks cache**: Have I looked this up recently? If yes and TTL hasn't expired, use the cached IP.
  • **Ask the recursive server**: If not cached, your computer asks a recursive DNS server (usually your ISP's or a public one).
  • **Recursive server checks its cache**: Has anyone asked recently? If yes and TTL is valid, return that.
  • **Recursive server does the lookup**: If not cached, it queries:
  • - Root servers: "Who handles .com?"

    - TLD servers: "Who handles example.com?" (they return the nameservers)

    - Authoritative servers: "What's the IP for example.com?" (they return the answer)

  • **Answer returned and cached**: The recursive server caches the answer (for the TTL duration) and sends it back to your browser.
  • **Browser connects**: Now that it has the IP address, your browser can connect to the server and load the page.

  • This entire process usually takes milliseconds. DNS lookups are one of the 7 things your browser does before a page loads.


    Quick reference


    | Term | What it means |

    |------|---------------|

    | DNS | The system that translates domain names to IP addresses |

    | Authoritative server | Official source that owns the DNS records for a domain |

    | Recursive server | Server that looks up DNS answers on your behalf |

    | TTL | How long a DNS answer can be cached (in seconds) |

    | Nameserver | Authoritative server configured for a domain |

    | Cache | Temporary storage of DNS answers to speed up lookups |

    | Propagation | Time it takes for DNS changes to spread (really: caches expiring) |




    Want to go deeper?


    The Journey of a URL — interactive lesson on what happens when you press Enter in your browser


    What DNS Does — a quick 3-minute bit on DNS basics


    7 Things Your Browser Does Before a Page Loads — the full picture including DNS




    *This post is part of Hacking Bits, where we explain how everyday technology works — one bit at a time.*


    Related Posts