Subscribe to receive notifications of new posts:

Introducing the Cloudflare Cache Purge Feature

2010-11-12

2 min read

Caching is great. Cloudflare makes sites faster in part by taking the static portions of your site and moving them closer to the visitors to your site. Cloudflare is smart about only caching static objects so you can run a dynamic, database-driven site and it will behave as you expect. However, sometimes you want to edit static files like CSS, Javascript, or existing images and it can be frustrating to wait a few hours for the Cloudflare cache to expire. There are two ways to deal with this problem:

Go to Development ModeDevelopment Mode bypasses Cloudflare's accelerated cache and slows down your site, but is useful if you are making changes to cacheable content (like images, css, or JavaScript) and would like to see those changes right away. You can get to Development Mode by going to:Settings->Cloudflare Settings->Development Mode->Toggle On.

Purge CacheWe read every email and tweet that we get. Often users write in with feature requests and we aim to build the most common ones quickly. This week, we released a new Cloudflare feature based on user feedback called the "Cache Purge". Some frequently asked questions about the "Cache Purge" can be found below:

Where can I find the purge cache option?The cache purge option is found by going to Settings->Cloudflare settings.

What does the cache purge option do?Cache purge will Immediately purge all cached resources for your website. This will force Cloudflare to expire all static resources cached prior to the button click and fetch a new version.

I have more than one domain. Do I have to purge the cache for eachsite?The cache purge is done at the domain level (purging will refresh thecache for all your websites that share a domain).

Can I only purge certain file extensions?No, not at this time. Please contact us if you would like to see us develop additional caching features.

How often should I purge my cache?You should purge your cache if there is a cached resource that you want to immediately stop serving. If you are doing development and making constant changes, use Development Mode instead.

Keep in mind...You will end up slowing down your site if you're constantly purging resources from your site. When you purge the cache, that means we have to fetch all requested resources from your server. It will take up to 3 days to rebuild the cache to an optimal level depending on the traffic to your site. What this really means is that your site will not be at optimal performance until the cache rebuilds.

Cloudflare's connectivity cloud protects entire corporate networks, helps customers build Internet-scale applications efficiently, accelerates any website or Internet application, wards off DDoS attacks, keeps hackers at bay, and can help you on your journey to Zero Trust.

Visit 1.1.1.1 from any device to get started with our free app that makes your Internet faster and safer.

To learn more about our mission to help build a better Internet, start here. If you're looking for a new career direction, check out our open positions.
CacheSpeed & ReliabilityProduct News

Follow on X

Cloudflare|@cloudflare

Related posts

October 24, 2024 1:00 PM

Durable Objects aren't just durable, they're fast: a 10x speedup for Cloudflare Queues

Learn how we built Cloudflare Queues using our own Developer Platform and how it evolved to a geographically-distributed, horizontally-scalable architecture built on Durable Objects. Our new architecture supports over 10x more throughput and over 3x lower latency compared to the previous version....

October 08, 2024 1:00 PM

Cloudflare acquires Kivera to add simple, preventive cloud security to Cloudflare One

The acquisition and integration of Kivera broadens the scope of Cloudflare’s SASE platform beyond just apps, incorporating increased cloud security through proactive configuration management of cloud services. ...