DNS Fundamentals Explained
Nameservers vs DNS Records: What’s the Difference?
Two concepts that confuse almost everyone — finally explained clearly
📋 What’s in this guide
You’ve registered a domain. You’re setting up hosting. Somewhere in the process, someone tells you to “update your nameservers” or “add a DNS record” — and if you’re not sure what either of those means, or how they relate to each other, you’re not alone. This is one of the most common points of confusion in all of web hosting.
The problem is that nameservers and DNS records are part of the same system but operate at different levels of it. Mixing them up leads to broken websites, missing email, failed SSL verifications, and hours of frustrated troubleshooting.
This guide untangles them completely. By the end, you’ll understand exactly what each one does, how they work together, where to change them, and how to fix the most common problems that come up when things go wrong.
1. How the DNS System Works (The Big Picture)
Before diving into nameservers and DNS records individually, it helps to understand the system they both belong to: the Domain Name System (DNS).
The DNS is essentially the internet’s phone book. Humans navigate the web using domain names like yourwebsite.com. Computers navigate it using IP addresses like 104.21.45.32. The DNS translates one into the other — automatically, invisibly, millions of times per second across the internet.
When someone types your domain name into a browser, a remarkable chain of lookups happens in under 100 milliseconds:
What Happens When Someone Visits Your Website
In this chain, nameservers are the directory — they tell the internet where to look for your domain’s information. DNS records are the actual entries inside that directory — specific instructions like “the website lives at this IP address” or “email for this domain goes to that mail server.”
They’re part of the same system, but they do different jobs at different levels. That’s the core of the distinction this guide will make crystal clear.
2. What Are Nameservers?
Nameservers are specialized servers that store the DNS records for your domain and answer DNS queries about it. When the internet wants to know anything about your domain — where the website is, where to send email, whether the domain is verified for a particular service — it asks your nameservers.
Think of nameservers as the filing cabinet for your domain. The DNS records inside them are the individual files. Before anyone can look at the files, they first need to know which filing cabinet to open. That’s what nameservers determine.
What Nameservers Look Like
Nameservers are identified by domain names themselves, typically something like:
ns1.yourhostingprovider.comns2.yourhostingprovider.com
You’ll always have at least two nameservers — a primary and a secondary — for redundancy. If one goes down, the other can still answer queries for your domain.
Where Nameservers Are Set
Nameservers are configured at your domain registrar — the company where you registered your domain (GoDaddy, Namecheap, Google Domains, etc.). This is a critically important distinction: nameservers are set at your registrar, not at your host.
When you point your domain to a hosting provider, what you’re actually doing is logging into your registrar and changing your nameservers to point to the ones your host gives you. Once you do that, your hosting provider’s nameservers become the authoritative source for your domain’s DNS records.
Who Provides Nameservers?
Your nameservers are typically provided by whoever manages your DNS. This is usually:
- Your web hosting provider — most common for beginners. When you sign up with a host, they give you their nameservers to use.
- Your domain registrar — many registrars like Namecheap and GoDaddy also offer free DNS management, so you can keep your nameservers there.
- A dedicated DNS provider — services like Cloudflare, Amazon Route 53, or NS1 offer advanced DNS management with performance and security benefits.
One of the most common setups for slightly more advanced users is to point a domain’s nameservers to Cloudflare, even if the website is hosted elsewhere. Cloudflare acts as a DNS provider and also provides a free CDN, DDoS protection, and SSL. The website still lives on your hosting provider — Cloudflare just sits in front of it, managing DNS and routing traffic efficiently.
3. What Are DNS Records?
DNS records are the individual instructions stored inside your nameservers. Each record answers a specific question about your domain: Where is the website? Where does email go? Is this domain verified for Google Search Console?
A DNS zone — the complete collection of DNS records for your domain — is essentially a configuration file that maps your domain name to various services and IP addresses. You manage this zone through whatever interface your nameserver provider offers (your host’s control panel, Cloudflare’s dashboard, your registrar’s DNS settings, etc.).
The Key Insight: Records Are Specific Instructions
Where nameservers are broad — “this is where all information about this domain lives” — DNS records are precise. Each record has a type, a name, a value, and a TTL (time to live). Together these four elements tell the internet exactly what to do with a specific aspect of your domain.
A domain typically has anywhere from 5 to 50+ DNS records — one for the website, several for email, one for each subdomain, verification records for various services, and so on. But it only ever has one active set of nameservers at a time. Changing nameservers is like moving your filing cabinet to a new building; changing a DNS record is like updating a single file inside it.
4. Nameservers vs DNS Records: The Difference
Here’s the clearest way to understand the relationship:
🗂️ Nameservers
- The container — where DNS records are stored
- Set at your domain registrar
- You typically have 2–4 nameservers per domain
- Changing nameservers moves all DNS management to a new provider
- Changes take up to 48 hours to propagate globally
- Examples: ns1.siteground.net, ns1.cloudflare.com
- Managed in your registrar’s dashboard
📋 DNS Records
- The contents — the actual routing instructions
- Set at whoever your nameservers point to
- You can have dozens of records per domain
- Changing a record affects only that specific service
- Changes take minutes to a few hours depending on TTL
- Examples: A record, MX record, CNAME, TXT record
- Managed in your host’s or DNS provider’s dashboard
The Most Common Source of Confusion
The confusion usually happens because people try to add DNS records in the wrong place. Here’s the scenario: you sign up with a hosting provider, then you go back to your registrar to try to add DNS records there. But nothing works — because your nameservers now point to your hosting provider, which means your registrar’s DNS records are being completely ignored.
The rule is simple: DNS records only matter if they’re stored in the nameservers your domain is currently pointed at. If your domain’s nameservers point to Cloudflare, you manage DNS records in Cloudflare — not at your registrar, not at your host.
Adding or editing DNS records at your registrar when your nameservers point elsewhere. Those records exist but are completely invisible to the internet — your domain’s nameservers are the authoritative source, and anything outside them is ignored. Always confirm where your nameservers point before editing DNS records, and make changes in that same place.
5. DNS Record Types Explained
There are many types of DNS records, each serving a distinct purpose. These are the ones you’ll actually encounter in the real world.
The most fundamental record. Points your domain (or subdomain) to a specific IPv4 server address. This is what makes yoursite.com load from the right server.
yoursite.com → 104.21.45.32Same purpose as an A record, but for IPv6 addresses — the newer, longer address format. Many modern hosting setups use both A and AAAA records together.
yoursite.com → 2606:4700::6810:2d20An alias. Instead of pointing to an IP address, a CNAME points to another domain name. Commonly used for subdomains like www or to connect services like Shopify, HubSpot, or custom email links.
www.yoursite.com → yoursite.comMail Exchange records tell the internet where to deliver email for your domain. If you use Google Workspace or Microsoft 365 for email, you set their MX records here. Multiple MX records can exist with priority values — lower number = higher priority.
@ → aspmx.l.google.com (priority 1)TXT records hold plain text and are most commonly used for domain verification (Google Search Console, email authentication, third-party service setup). SPF and DKIM records that protect your email from spoofing are also stored as TXT records.
@ → "v=spf1 include:_spf.google.com ~all"NS records identify which nameservers are authoritative for your domain. These exist within your DNS zone as a reference, but the ones that actually matter are set at your registrar — those take precedence.
@ → ns1.siteground.netTTL isn’t a record type but a setting on every record. It tells DNS resolvers how many seconds to cache a record before checking for updates. Lower TTL = faster propagation of changes but more DNS queries. Higher TTL = more caching efficiency, slower updates.
TTL: 3600 = cached for 1 hourEvery DNS zone has exactly one SOA record. It contains administrative information about the zone: the primary nameserver, the contact email of the zone administrator, and serial numbers used to sync between nameservers. You rarely need to edit this manually.
Auto-managed by your DNS providerLess Common But Worth Knowing
- SRV Record — specifies a host and port for a specific service (used by apps like Microsoft Teams, SIP phones, and game servers)
- CAA Record — specifies which Certificate Authorities are allowed to issue SSL certificates for your domain — a security measure
- PTR Record — reverse DNS, maps an IP address back to a domain name. Used by mail servers to verify email senders.
- DKIM Record — stored as a TXT record, contains a public key that mail servers use to verify your outgoing email hasn’t been tampered with
- DMARC Record — also a TXT record, tells receiving mail servers what to do if an email fails SPF or DKIM checks (reject, quarantine, or do nothing)
6. TTL: The Timing Factor Everyone Ignores
TTL (Time to Live) is the most overlooked DNS setting, and misunderstanding it causes a lot of unnecessary frustration when making DNS changes.
When a DNS resolver (your ISP’s DNS server, Google’s 8.8.8.8, Cloudflare’s 1.1.1.1) looks up a DNS record, it caches the result for the duration of the TTL. During that time, it won’t check for updates — it just serves the cached version. This is why DNS changes don’t take effect instantly even though you saved them immediately.
Common TTL Values and What They Mean
| TTL Value | Duration | When to Use |
|---|---|---|
| 300 | 5 minutes | When you’re actively making changes and need fast propagation |
| 900 | 15 minutes | Good for dynamic environments where records change occasionally |
| 3600 | 1 hour | Standard default — good balance of caching and flexibility |
| 14400 | 4 hours | Common hosting provider default |
| 86400 | 24 hours | Stable, rarely-changed records — maximum caching efficiency |
If you know you’re going to change hosting providers or make significant DNS changes, lower your TTL to 300 (5 minutes) 24–48 hours before you make the change. Once existing caches expire at your old TTL, the new short TTL kicks in — meaning your actual DNS changes will propagate in minutes instead of hours. After the migration is complete and stable, raise the TTL back to 3600 or higher.
7. Where to Manage Each One
One of the most practical things to understand is which dashboard to open when you need to make a DNS change. The answer depends entirely on where your nameservers point.
To Change Your Nameservers
Always done at your domain registrar — the company you bought the domain from. Log into your registrar’s dashboard, find your domain, look for “Nameservers” or “DNS” settings, and update the nameserver fields. Common registrars and where to find this:
- Namecheap: Domain List → Manage → Nameservers
- GoDaddy: My Products → DNS → Nameservers
- Google Domains / Squarespace Domains: DNS → Nameservers
- Cloudflare Registrar: DNS → Nameservers (tab)
To Add or Edit DNS Records
Done wherever your nameservers currently point. This is the variable part — it depends on your setup:
| Your Nameservers Point To | Where to Manage DNS Records | Where to Find It |
|---|---|---|
| Your web host | Hosting control panel | cPanel → Zone Editor, or your host’s DNS tool |
| Your registrar | Registrar’s DNS management | Same dashboard where you set nameservers |
| Cloudflare | Cloudflare dashboard | cloudflare.com → Your domain → DNS → Records |
| AWS Route 53 | Route 53 hosted zone | AWS Console → Route 53 → Hosted Zones → your domain |
| Google Cloud DNS | Cloud DNS zone | GCP Console → Network Services → Cloud DNS |
Use a free tool like dnschecker.org or mxtoolbox.com to look up your domain’s current nameservers. Enter your domain, select NS record type, and the tool will show you exactly which nameservers are authoritative for your domain right now. That’s where you need to go to manage DNS records.
8. Common Real-World Scenarios
Let’s walk through the most common situations people encounter, and exactly what to do in each one.
Scenario 1: Pointing a New Domain to Your Hosting Provider
What you need to do: Change nameservers at your registrar to the ones your hosting provider gives you.
- Log into your hosting account and find the nameservers they provide (usually in the welcome email or account dashboard — typically two addresses like ns1.hostname.com and ns2.hostname.com)
- Log into your domain registrar
- Find your domain → Nameservers → switch to “Custom nameservers”
- Enter the nameservers from your hosting provider
- Save and wait up to 48 hours for propagation
DNS records: Once propagation completes, your host will typically have already set up the basic A record pointing to your server. Check your hosting control panel’s DNS/Zone Editor to confirm.
Scenario 2: Adding Google Workspace Email to Your Domain
What you need to do: Add MX records and TXT records — but in the right place.
- Find out where your nameservers point (your registrar or your host)
- Log into that dashboard (registrar DNS management, cPanel Zone Editor, or Cloudflare)
- Delete any existing MX records for your domain
- Add the five Google Workspace MX records Google provides
- Add the TXT record for SPF authentication Google provides
- Add the DKIM TXT record after completing Google Workspace setup
Scenario 3: Connecting a Custom Domain to a Third-Party Service (Shopify, Webflow, etc.)
What you need to do: Usually add a CNAME record or change the A record, following the service’s exact instructions.
- Shopify: Add an A record pointing @ to Shopify’s IP, and a CNAME for www pointing to shops.myshopify.com
- Webflow: Add two A records for the root domain and a CNAME for www
- Squarespace: Uses CNAME and A record combination — follow their specific setup wizard
Always follow the exact instructions from the third-party service — don’t guess at record types or values. They know what their infrastructure requires.
Scenario 4: Verifying Your Domain for Google Search Console
What you need to do: Add a TXT record with Google’s verification string.
- In Search Console, choose “Domain” verification method
- Copy the TXT record value Google gives you
- Go to wherever your nameservers point
- Add a new TXT record: Name = @ (root domain), Value = the Google string
- Click verify in Search Console — it may take a few minutes to detect the record
TXT records from different services can coexist — you can have an SPF record, a Google verification record, and a HubSpot verification record all as TXT records simultaneously. Never delete an existing TXT record without knowing what it’s for. Deleting an SPF record breaks email deliverability; deleting a verification record deauthorizes a connected service.
9. Troubleshooting DNS Problems
When something DNS-related isn’t working, these are the steps that solve it in the vast majority of cases.
Website Not Loading After Changing Nameservers
- First check: How long ago did you change nameservers? If less than 48 hours, it may simply not have propagated yet. Use dnschecker.org to see propagation status across global DNS servers.
- Check if the A record exists: Log into your host’s DNS management and confirm an A record exists pointing your domain to your server’s IP address.
- Try a different DNS server: Flush your local DNS cache (
ipconfig /flushdnson Windows,sudo dscacheutil -flushcacheon Mac) or test with Google’s DNS (8.8.8.8) using a tool like nslookup.
Email Not Delivering After Setting Up Email Hosting
- Confirm MX records are in the right place: Check that your MX records are in the DNS zone your nameservers point to — not at your registrar if nameservers are elsewhere.
- Check for MX record conflicts: Old MX records from a previous email provider can conflict with new ones. Delete all existing MX records before adding new ones.
- Verify SPF and DKIM records exist: Email deliverability often fails silently if SPF/DKIM records are missing. Use mxtoolbox.com’s Email Health check to diagnose.
SSL Certificate Won’t Issue
- SSL verification often requires a specific TXT or CNAME record. Confirm it’s been added to the correct DNS zone (where your nameservers point).
- Wait for TTL to expire after adding the record — SSL verification checks can fail if they run before the record propagates.
- If using Cloudflare, ensure the record is in Cloudflare’s DNS — not at your registrar.
DNS Changes Not Taking Effect
- The most common cause: you edited records at your registrar, but your nameservers point to your host or Cloudflare. Those registrar records are invisible. Make the change in the right place.
- Second most common: TTL is set to 86400 (24 hours) and you’re not waiting long enough. Use a tool like whatsmydns.net to check real-time propagation globally.
10. DNS Propagation Explained
“Propagation” is the process by which DNS changes spread across the internet’s distributed network of DNS resolvers. When you update a DNS record, you’re updating it in one place — your nameserver. But the internet has thousands of DNS resolvers, and each one may have a cached copy of your old record that won’t expire until its TTL runs out.
Why Propagation Isn’t Instant
The internet has no central DNS server. It’s a distributed, hierarchical system where resolvers at ISPs, companies, and public providers (like Google’s 8.8.8.8 and Cloudflare’s 1.1.1.1) all maintain their own caches. When you change a DNS record, each resolver only gets the update when its cached version expires and it makes a fresh query to your nameservers.
Realistic Propagation Timelines
| Change Type | Typical Wait Time | Maximum Wait |
|---|---|---|
| DNS record change (TTL 300) | 5–15 minutes | 30 minutes |
| DNS record change (TTL 3600) | 1–2 hours | 4 hours |
| DNS record change (TTL 86400) | 12–24 hours | 48 hours |
| Nameserver change | 2–12 hours | 48 hours |
| New domain registration | 15 minutes–4 hours | 24 hours |
11. Quick Reference Cheat Sheet
Bookmark this section. It’s the fast-access summary of everything in this guide.
The Key Distinction
- Nameservers = the filing cabinet. Set at your registrar. Tell the internet where your domain’s DNS records live.
- DNS Records = the files inside. Set wherever your nameservers point. Tell the internet what to do with each part of your domain.
- If you change nameservers, you must manage DNS records at the new provider — old records at your registrar are ignored.
- Always confirm where your nameservers point before editing DNS records — use dnschecker.org (NS lookup) if unsure.
DNS Record Quick Reference
| Record Type | What It Does | Common Use Case |
|---|---|---|
| A | Domain → IPv4 address | Point domain to web server |
| AAAA | Domain → IPv6 address | Point domain to IPv6 web server |
| CNAME | Domain → another domain | www subdomain, third-party services |
| MX | Email routing | Direct email to Google Workspace / M365 |
| TXT | Text data / verification | SPF, DKIM, domain ownership proofs |
| NS | Declares nameservers | Set at registrar — not typically edited manually |
| CAA | SSL certificate authority control | Restrict which CAs can issue SSL for your domain |
| PTR | IP → domain (reverse DNS) | Mail server reputation, set by your host |
Before You Make Any DNS Change
- Look up your current nameservers using dnschecker.org (NS record type)
- Log into the dashboard for whoever those nameservers belong to
- If making a major change, lower TTL to 300 at least a few hours in advance
- Note down existing record values before changing them — easy rollback if needed
- After making changes, verify propagation using dnschecker.org or whatsmydns.net
- For email changes, run a full email health check on mxtoolbox.com after propagation
Same System,
Different Levels
Nameservers and DNS records aren’t competing concepts — they’re two layers of the same system, and understanding which layer you’re working at is the key to making confident DNS changes. Nameservers decide where the rules are kept. DNS records are the rules themselves.
Once you internalize that one distinction — and always confirm where your nameservers point before touching DNS records — the confusion that trips up so many people simply disappears. The tools are straightforward, the logic is consistent, and the troubleshooting process becomes methodical rather than mysterious.
DNS only feels complicated until it clicks. After that, it’s just a lookup table you happen to be in charge of.
Know where your nameservers point.
Make changes in that same place. Done.