Fix a CDN that serves stale content
We'll confirm the origin is correct, purge the cache, lower TTL, and verify the edge serves fresh content—or tell you when to contact your CDN provider.
What you'll need
- CDN dashboard access (Cloudflare, Fastly, or your provider)
- The URL or path that is stale
Step-by-step diagnostic
Quick triage — pick your path
Quick triage — pick your path
Choose the option that matches what you see. You can jump straight to that section.
- Follow this guide Work through the full procedure from origin check to purge.
- Purge by URL One page is stale and you know the exact URL.
- Purge by path or zone Multiple pages or the whole site is stale.
- Lower TTL You want faster propagation for future updates.
- When to contact provider Purge fails or content stays stale after purge.
Show full guide
Steps
Goal: Confirm the origin, purge the cache, and verify the edge serves fresh content.
- Check that your origin server serves the updated content. Use
curl -H "Cache-Control: no-cache" -I https://yoursite.com/pathto bypass cache. - Good: Origin shows correct content. Proceed to Purge by URL.
- Bad: Origin shows old content—fix the origin first. The CDN caches what it receives.
Purge by URL
Goal: Remove cached content for a single stale page.
- Log into your CDN dashboard (Cloudflare, Fastly, BunnyCDN, or your provider). Find the Caching or Purge section.
- Enter the full URL (e.g.
https://yoursite.com/page) and run purge. Most CDNs purge within seconds. - Good: Purge succeeds. Test in incognito—you should see fresh content.
- Bad: Purge fails—check rate limits, try path purge, or see When to get help.
Purge by path or zone
Goal: Remove cached content for multiple pages or the whole site.
- For several pages under a path, use path purge. Enter the path (e.g.
/blogor/assets). - For the entire site, use full zone purge. Some plans limit full purges per day.
- Good: Purge succeeds. The next request fetches fresh content from the origin.
- Bad: Purge fails or content stays stale—lower TTL or contact provider.
Lower TTL
Goal: Reduce how long content stays cached so future updates propagate faster.
- In the CDN cache settings, find TTL for HTML or assets. Lower it (e.g. 5 minutes instead of 1 hour) for content that changes often.
- Leave higher TTL for static assets (images, CSS, JS) that rarely change.
- Good: TTL is set. Future updates will propagate within the new TTL window.
- Bad: No TTL control—your plan may not support it; contact provider.
Verify the edge
Goal: Confirm the edge serves fresh content after purge.
- Load the page in incognito mode or add
?nocache=1to the URL. - Run
curl -I https://yoursite.com/pathand check thecf-cache-status(Cloudflare) orx-cacheheader. You should see MISS or BYPASS, not HIT with old content. - Good: Content is fresh. The edge is serving the updated version.
- Bad: Still stale—lower TTL, purge again, or contact provider.
When to get help
Contact your CDN provider if:
- Purge consistently fails or returns errors.
- You hit purge rate limits and need an immediate fix.
- Content stays stale after a successful purge (origin may be cached elsewhere).
- You cannot find purge or TTL settings in your dashboard.
Verification
- The origin serves the correct content when checked with a cache-bypass request.
- Purge succeeds in the CDN dashboard.
- The edge serves fresh content (MISS or BYPASS in cache headers) when tested in incognito.
- TTL is set appropriately for content that changes often.
Escalation ladder
Work from the device outward. Stop when the problem is fixed.
- Confirm origin Verify the origin serves correct content.
- Purge by URL Purge the stale URL from the CDN dashboard.
- Purge by path or zone Purge path or full zone if multiple pages stale.
- Lower TTL Reduce TTL for faster future updates.
- Contact provider CDN support if purge fails or content stays stale.
What to capture if you need help
Before calling support or posting for help, have these ready. It speeds everything up.
- CDN provider and plan
- URL or path that is stale
- Purge time and result (success or error)
- TTL settings
- Steps already tried
Does the origin serve the correct content?
The CDN caches what the origin sends. If the origin is wrong, the CDN will cache wrong content.
You can change your answer later.
Fix the origin first
Purge the stale URL or path
Purge tells the CDN to remove cached content so the next request fetches fresh.
You can change your answer later.
Does the edge serve fresh content now?
Test in incognito or with cache-bypass to avoid local cache.
You can change your answer later.
Lower TTL and retest
Contact CDN provider
CDN serves fresh content
Reviewed by Blackbox Atlas
Frequently asked questions
- Why does a CDN serve stale content?
- CDNs cache content at edge locations for speed. When you update your site, the edge cache still holds the old version until it expires (TTL) or you purge it. A long TTL or failed purge keeps stale content live.
- What is a CDN purge?
- A purge tells the CDN to remove cached content immediately so the next request fetches fresh content from the origin. Most CDNs offer URL purge, path purge, or full zone purge.
- When should I lower TTL instead of purging?
- Lower TTL for content that changes often—it reduces how long stale content can persist. Use purge when you need an immediate fix for a specific update.
Rate this guide
Was this helpful?
Thanks for your feedback.