juniorCDN
What is TTL (Time to Live)?
Updated Apr 28, 2026
Short answer
TTL is a setting that determines how long a file should be cached on an edge server before being refreshed.
Deep explanation
CDN architecture involves a network of proxy servers. When a user requests content, the DNS routes them to the nearest Edge server. This minimizes the physical distance data travels (the 'last mile'), reducing round-trip time (RTT). Key protocols like TCP and TLS are terminated at the edge, further speeding up the handshake process.
Real-world example
A user in Tokyo accessing a website hosted in New York. Without a CDN, the request travels across the ocean. With a CDN, the user gets the image from a Tokyo-based edge server.
Common mistakes
- Thinking a CDN replaces a web host
- it actually acts as a performance layer on top of it.
Follow-up questions
- How does DNS-based routing work in CDNs?
- Can static and dynamic content both be served via CDN?