How to Debug DNS Propagation Delays Using dig and nslookup
After updating an A record, switching hosting providers, or pointing a domain to Cloudflare, waiting while different devices show different websites feels frustrating. People often call all of this “DNS propagation delay,” yet DNS does not actually push updates across the internet in a single wave. Instead, recursive resolvers cache old answers until their Time to Live (TTL) expires, or a registrar still holds stale nameserver or DNSSEC records. Two built-in command-line tools—dig and nslookup—let you pinpoint the exact layer that is stuck in under two minutes.
Editorial illustration: verify the authoritative nameserver first, then compare recursive resolvers and DNSSEC DS records.
Summary
- Always query your authoritative nameserver first so you know whether the DNS provider actually published your new record.
- Compare recursive resolvers (your local ISP,
1.1.1.1, and8.8.8.8) and read the remaining TTL rather than assuming “propagation failed.” - Check
dig +traceanddig DSwhen moving DNS providers: staleDSrecords at your domain registrar causeSERVFAILerrors even when nameservers look right. - Remember that Cloudflare-proxied records intentionally return Cloudflare edge IPs rather than your origin server’s IP address.
Why DNS changes appear inconsistent across devices
When you update a DNS record, two separate systems determine what a visitor sees:
- The authoritative zone: Your DNS provider’s nameservers hold the source of truth. If the authoritative nameserver still returns the old value, waiting 24 hours will not fix anything—your edit was either saved to the wrong zone or not published.
- Recursive resolver caches: Your ISP, office router, browser, and public resolvers such as Cloudflare (
1.1.1.1) or Google (8.8.8.8) cache DNS answers for the duration of the record’s TTL (measured in seconds). As noted in Namefi’s DNS propagation troubleshooting guide, lowering a TTL after a resolver already cached the old answer does not flush that existing cache early.
On top of that, negative caching means a resolver that previously saw NXDOMAIN (non-existent domain) for a brand-new subdomain can keep caching that “not found” answer briefly even after you create the record.
Step-by-step: Diagnose a DNS change with dig and nslookup
1. Check what the parent zone delegates (NS records)
If you recently moved DNS providers (for example, switching nameservers to Cloudflare), confirm that your domain registrar actually published the new nameservers at the parent TLD. Per Cloudflare’s Pending Nameserver Update troubleshooting docs, run:
dig +trace example.com NS +noall +authority +nodnssec
Or on Windows / systems without dig:
nslookup -type=ns example.com
If the output still lists your old host’s nameservers, the problem is at your registrar (for instance, an unconfirmed email prompt, a registrar lock, or a missed Save button)—not at your new DNS provider.
2. Query the authoritative nameserver directly
Next, bypass your local ISP cache and ask the authoritative nameserver directly using @nameserver and +norecurse:
dig @ns1.example-dns.net www.example.com A +norecurse
Check two things in the response:
- The ANSWER SECTION shows the exact IP or target you saved.
- The flags line includes
aa(Authoritative Answer).
If the authoritative server returns the old value, verify you are editing the active DNS zone (many teams accidentally edit DNS inside an old hosting cPanel while their domain’s nameservers point to Cloudflare or a separate registrar).
3. Compare public recursive resolvers and inspect TTL
Once you know the authoritative record is right, compare what recursive resolvers see:
dig @1.1.1.1 www.example.com A
dig @8.8.8.8 www.example.com A
Look at the number immediately after the domain name in the ANSWER SECTION—for example, 245 IN A 192.0.2.20. That 245 is the remaining TTL in seconds. Run the same command 10 seconds later; if it counts down (235), the resolver is simply serving a cached copy until the timer hits zero.
4. Check for stale DNSSEC DS records if you see SERVFAIL
If your new nameservers appear in dig +trace, yet resolvers return SERVFAIL or your Cloudflare zone stays in Pending status, check for leftover DNSSEC records:
dig DS example.com
As Cloudflare’s full-setup and DNSSEC documentation explains, DS records live at your domain registrar, not inside your DNS zone. If DNSSEC was enabled at your previous DNS provider and you switched nameservers without turning DNSSEC off first, resolvers fail cryptographic validation and return SERVFAIL until you remove the stale DS record at the registrar.
5. Distinguish DNS answers from HTTP caching
If dig confirms your domain resolves to the right IP or Cloudflare proxy address, yet your browser still displays yesterday’s webpage, the delay is no longer DNS—it is HTTP or edge caching. At that point, follow our checklist on purging a stale page on Cloudflare or check website server location and latency.
Common mistakes
- Checking a proxied Cloudflare record and expecting your origin IP. When a record is orange-clouded (proxied) in Cloudflare, public
digqueries intentionally return Cloudflare anycast IPs rather than your origin server’s IP. - Querying the wrong record type or hostname. Checking
example.com Awhen you only updatedwww.example.com CNAME—or checkingAwhen your mail issue is inMXorTXT—leads to false alarms. - Repeatedly saving the same DNS edit. Re-saving a record in your dashboard does not force global recursive resolvers to clear their TTL early.
- Assuming green checkmarks on a web propagation tool mean every visitor sees the update. Online checkers only sample a handful of public resolvers; an office router or mobile carrier can still hold an older cached record until its TTL expires.
Why this matters
Guessing during a DNS cutover leads to panic-editing live records and extending downtime. Separating authoritative verification from recursive TTL caching and DNSSEC checks tells you within minutes whether you should wait out a timer or fix a registrar setting.
My Take
Lower your critical record TTLs to 300 seconds (5 minutes) a day before any planned server migration, and keep dig +trace and dig @1.1.1.1 as your first two checks on cutover day. Ninety percent of “propagation mysteries” turn out to be either a remaining TTL countdown, an inactive DNS zone, or an old DNSSEC DS record left behind at the registrar.
Conclusion
When a DNS change seems stuck, trace delegation with dig +trace, verify the authoritative answer directly, compare 1.1.1.1 and 8.8.8.8 TTL countdowns, and run dig DS if resolvers return SERVFAIL. Once the authoritative server and DS records are clean, you know with certainty that remaining differences are just normal TTL expiration.