Understanding DNS TTL is one of those topics that seems simple until a migration goes wrong. You change a DNS record, wait, and half the internet still reaches the old server. The culprit is almost always the TTL, the time-to-live value that tells resolvers how long they may cache your record before asking again.
TTL controls how quickly DNS changes spread, how much load your nameservers take, and how fast you can fail over when something breaks. Getting it right is mostly a matter of planning ahead, because the TTL you need during a change is not the TTL you want the rest of the year.
Understanding DNS TTL in Practice
Every DNS record carries a TTL, measured in seconds. When a resolver, such as the one your ISP or your company’s network runs, looks up your domain, it stores the answer for exactly that long. Further queries inside the TTL window get the cached answer instantly, without contacting your nameserver again.
A TTL of 3600 means one hour of caching. A TTL of 300 means five minutes. Lower values make changes propagate faster, but they also mean resolvers query your nameserver more often. Higher values cut query load and make lookups faster for users, but they slow down every change you make later.
Common TTL values you will see in the wild include 300 for records that change often, 3600 as a general default, and 86400 for stable records that rarely move. There is no universal best value, only the right value for how often that particular record changes.
How DNS Caching Really Works, Layer by Layer
Caching happens at more than one level, which is why a DNS change can seem instant for one person and slow for another:
- Browser cache: browsers cache DNS results briefly, often for a minute or so, regardless of your TTL.
- Operating system cache: your computer’s resolver cache holds answers for up to the record’s TTL.
- Recursive resolver cache: the resolver run by your ISP or network caches the answer for the full TTL. This is the layer that usually dominates propagation time.
- Authoritative nameserver: this is the source of truth. It does not cache; it answers from your zone configuration.
Some resolvers also ignore very low TTLs and enforce a minimum cache time of their own, which is why a TTL of 30 seconds does not guarantee 30-second propagation everywhere. A record’s TTL is a request, not a command: well-behaved resolvers honor it, but nothing forces every resolver on the internet to comply.
This layered behavior is also why choosing the right DNS provider matters. Providers differ in how quickly they publish zone changes and how their anycast networks spread them, and anycast DNS helps answers reach users faster once the cache expires.
Why DNS Propagation Feels Slow
When people say DNS is “propagating,” what is usually happening is caches expiring at different times. A resolver that cached your old record one minute before your change will keep serving it for the rest of its TTL. A resolver that had never seen your domain answers with the new record immediately. That mix is why propagation checkers show a patchwork of old and new answers for hours.
The fix is not to wait longer. The fix is to lower the TTL before you make the change. If your record currently has a TTL of 86400 and you need to move it tomorrow, lower the TTL to 300 today. Wait at least 24 hours, so every cache holding the old long TTL expires and re-fetches the short one. Then make your change, and the whole internet converges within about five minutes instead of a day.
The same principle applies to every record type. If you are still fuzzy on what each record does, a rundown of A, AAAA, CNAME, MX, and TXT records helps you decide which TTLs matter for web traffic versus mail versus verification records.
Picking the Right TTL for Each Situation
Think of TTL as a dial between speed of change and query load:
- Records you plan to change soon: lower the TTL before the change to 300, a day or more ahead. Raise it back afterward.
- Stable web records: 3600 to 86400 is reasonable. Your server IP rarely changes, so long caching helps performance.
- Failover records: keep the TTL low, 60 to 300 seconds, if you rely on DNS to shift traffic when a server fails. A one-hour TTL makes DNS failover nearly useless.
- MX records: mail servers retry delivery, so a moderate TTL of 3600 is usually fine. Mail does not need instant cutover the way web traffic does.
- TXT verification records: TTL barely matters, since verifiers query them directly and infrequently.
One caution: very low TTLs on every record raise your nameserver query volume, and some providers bill by query count or rate-limit aggressive resolvers. Keep low TTLs on the handful of records that actually need them, not on the whole zone.
TTL Mistakes That Cause Real Outages
The classic mistake is changing an IP with a 24-hour TTL still in place, then discovering that users keep landing on a decommissioned server. The second classic mistake is the reverse: leaving a TTL at 60 seconds forever, which adds latency to every first lookup and needless load to your nameservers.
A third mistake is assuming a local test proves propagation. Clearing your own browser cache does not clear your ISP’s resolver cache, and neither proves what users in other regions see. Use a global DNS checker to sample resolvers worldwide, and check from a network you do not control before declaring a migration done. For a full migration plan, including TTL timing, see a guide to migrating VPS providers with zero downtime.
A Simple TTL Workflow for Changes
- At least one old-TTL period before the change, lower the TTL on the affected records to 300.
- Wait out the old TTL so all caches pick up the short value.
- Make the record change.
- Verify from several global resolvers that the new answer is spreading.
- Once stable, raise the TTL back to a normal value such as 3600.
DNS TTL is a small number with outsized consequences. Set it low before you need speed, set it high when you need stability, and never make a record change without checking what the current TTL is first. That one habit prevents most of the “DNS is broken” incidents that are really just caches doing exactly what they were told.