Free Online Toolbox for developers

Why your DNS change is not showing up yet: TTLs, caches and propagation explained

You changed a DNS record ten minutes ago. Your colleague already sees the new server, you still see the old one, and a customer in another country sees something else again. The usual explanation is “DNS propagation, give it 48 hours”. That advice is not exactly wrong, but it hides what is really going on, and once you understand the mechanism you can make most DNS changes take effect in minutes instead of days.

DNS changes do not propagate. Caches expire.

The word “propagation” suggests that your change is pushed out across the internet, server by server. That is not how DNS works. When you edit a record at your DNS provider, the change is live on your authoritative name servers almost immediately. Nothing is pushed anywhere.

What delays the change is caching. When a user’s device looks up your domain, it asks a recursive resolver, usually run by their ISP, their company or a public service such as Google Public DNS, Cloudflare or Quad9. That resolver fetches the answer from your authoritative servers and then keeps it in its cache for as long as the record’s TTL allows. Until the cached copy expires, the resolver keeps handing out the old answer. Different resolvers fetched the record at different times, so their caches expire at different times, and that is why different people see different results.

TTL is the number that controls everything

Every DNS record carries a TTL, or time to live, in seconds. A TTL of 3600 means resolvers may cache the answer for an hour. A TTL of 86400 means a full day. When people say a change takes up to 48 hours, they are really describing the worst case for records with long TTLs, plus resolvers that hold on to answers longer than they should.

The key detail is that the TTL that matters is the one resolvers saw before your change. If the record had a TTL of 86400 yesterday and you lower it to 300 now, resolvers that cached it yesterday will still keep the old answer for up to a day. Lowering the TTL only helps if you do it in advance.

The other caches nobody mentions

Recursive resolvers are the main cache, but not the only one:

  • Negative caching. If someone looked up a name before it existed, resolvers cache the “does not exist” answer too. The duration comes from your zone’s SOA record, as defined in RFC 2308. A new subdomain can stay invisible for some users for the length of that negative TTL, even though the record now exists.
  • Operating system caches. Windows, macOS and many Linux systems keep their own DNS cache. A user may need to flush it or simply wait.
  • Browser caches. Browsers cache DNS results and keep connections open to the old address. Restarting the browser often “fixes” DNS for one person.
  • Application caches. Long-running services, such as a Java application or a reverse proxy, may resolve a hostname once at startup and never again until restarted.

Name server changes are a special case

Changing name servers, for example when moving a domain to a new DNS provider, really can take a day or two. The delegation for your domain lives in the parent zone run by the registry, such as .com, and those NS records commonly have a TTL of 48 hours. Resolvers that cached the old delegation keep asking your old provider until it expires.

The safe way to handle this is to make both providers serve identical records during the transition. Copy the full zone to the new provider, change the name servers at the registrar, and leave the old zone in place for at least 48 hours. Whichever provider a resolver asks, it gets the same answer, and users notice nothing.

How to check what the world actually sees

When a change seems slow, the first step is to separate two questions: is the authoritative server answering correctly, and which resolvers still have the old answer cached?

For the first question, query your authoritative name server directly with a lookup tool such as dig or nslookup, pointing it at the name server instead of your default resolver. If the authoritative answer is wrong, the problem is your zone, not propagation, and waiting will not help.

For the second question, compare the answers of several public resolvers at once. A DNS propagation checker sends the same query for A, AAAA, CNAME, MX, NS, TXT or CAA records to a set of well-known public resolvers and shows their answers side by side. If most resolvers already return the new value and one or two still show the old one, you are simply waiting for their caches to expire. If none of them show the change, go back and check the authoritative server.

A simple plan for changes without surprises

For planned changes, such as moving a website to a new server or switching email providers, this sequence keeps the transition short and predictable:

  1. Lower the TTL early. At least one full old TTL before the change, reduce the TTL of the records you will modify to 300 seconds. If the old TTL was a day, do this a day ahead.
  2. Prepare the new target. Make sure the new server or service is ready and working before you point DNS at it.
  3. Make the change. Update the record. With a short TTL in place, most resolvers pick it up within minutes.
  4. Verify from several resolvers. Check that public resolvers return the new answer, and test the service itself through the new address.
  5. Keep the old target running for a while. Some resolvers and long-running clients ignore TTLs. Leave the old server running, or redirecting, for a day or two.
  6. Raise the TTL again. Once everything is stable, restore a longer TTL, such as an hour, to reduce query load and improve resilience.

Key takeaways

  • DNS changes are instant at the source. Delays come from caches holding old answers until their TTL expires.
  • The TTL that matters is the old one, so lower it before you make the change, not at the same time.
  • Negative caching, operating systems, browsers and applications add their own delays.
  • Name server changes depend on the registry’s TTL, so run both providers in parallel during a migration.
  • Check the authoritative server first, then compare public resolvers to see how far the change has spread.

With a little planning, “wait 48 hours” becomes “wait five minutes”, and the next DNS change will be one of the least eventful parts of your deployment.




Suggested Reads