Title: Amazon Cloudfront Invalidations
Last modified: June 7, 2018

---

# Amazon Cloudfront Invalidations

 *  [Greg Marshall](https://wordpress.org/support/users/gmarsh/)
 * (@gmarsh)
 * [7 years, 11 months ago](https://wordpress.org/support/topic/amazon-cloudfront-invalidations/)
 * I have this plugin running on two sites that use Amazon Cloudfront for the CDN.
   On May 3, one site started sending invalidations to Cloudfront. At first there
   were anywhere from a few to 1000 invalidations per day. Starting May 19, there
   were 7000 invalidations per day. Amazon charges $0.005 per invalidation after
   1000, so I ended up with a $500 bill for Cloudfront for May.
    I have disabled
   the CDN for now, so it stopped. As far as I can tell, W3 Total Cache was the 
   only plugin updated around that time, and the only one that should affect CDN.
   I saw another post which said to use the generic setting instead of the Cloudfront
   setting, so I will give that a try. Is there anything else I can do to make sure
   this doesn’t happen again?
 * Thanks!

Viewing 15 replies - 1 through 15 (of 23 total)

1 [2](https://wordpress.org/support/topic/amazon-cloudfront-invalidations/page/2/?output_format=md)
[→](https://wordpress.org/support/topic/amazon-cloudfront-invalidations/page/2/?output_format=md)

 *  Thread Starter [Greg Marshall](https://wordpress.org/support/users/gmarsh/)
 * (@gmarsh)
 * [7 years, 11 months ago](https://wordpress.org/support/topic/amazon-cloudfront-invalidations/#post-10372715)
 * For what it’s worth, here are the plugins that did update on May 3, when the 
   problem started:
    May 3 06:54 w3-total-cache/ May 3 06:54 flowpaper-lite-pdf-
   flipbook/ May 3 06:54 enable-media-replace/ May 3 06:54 advanced-nocaptcha-recaptcha/
 *  Plugin Contributor [gidomanders](https://wordpress.org/support/users/gidomanders/)
 * (@gidomanders)
 * [7 years, 11 months ago](https://wordpress.org/support/topic/amazon-cloudfront-invalidations/#post-10372982)
 * It is W3 that generates the invalidation requests, but we’re working on an option
   to only invalidate on manual purges. So for now the generic mirror works good
   enough, but in a future release you can use the CloudFront specific CDN option
   again.
 *  [ratul29](https://wordpress.org/support/users/ratul29/)
 * (@ratul29)
 * [7 years, 11 months ago](https://wordpress.org/support/topic/amazon-cloudfront-invalidations/#post-10429644)
 * you guys ruined my AWS bill. I have a massive $100 bill in just 2 days. This 
   is shameful on you guys.
 *  Plugin Contributor [gidomanders](https://wordpress.org/support/users/gidomanders/)
 * (@gidomanders)
 * [7 years, 11 months ago](https://wordpress.org/support/topic/amazon-cloudfront-invalidations/#post-10429754)
 * We’re very sorry to hear that. We’re working on the solution to be released as
   soon as possible.
 *  [familyhardware](https://wordpress.org/support/users/familyhardware/)
 * (@familyhardware)
 * [7 years, 10 months ago](https://wordpress.org/support/topic/amazon-cloudfront-invalidations/#post-10478298)
 * I have had the same issue with the plugin. This was on a simple WooCommerce site
   with a few thousand products. Notice it incurred over $6,000 in fees.
 * Amazon CloudFront Invalidations $6,485.76
    $0.000 per URL – first 1,000 URLs /
   month.1,000 URL$0.00 $0.005 per URL – over 1,000 URLs / month.1,297,151 URL$6,485.76
 *  [hileon](https://wordpress.org/support/users/hileon/)
 * (@hileon)
 * [7 years, 10 months ago](https://wordpress.org/support/topic/amazon-cloudfront-invalidations/#post-10539278)
 * We are experiencing the same issue now, it cost us 150$ in about only 1 hour.
   
   [Cost hundreds of $ when W3TC invalidating Cloudfront CDN records.](https://twitter.com/hileon/status/1023844538392039424)
 * Is there a option to purge CDN manually instead of let it done by w3tc automatically?
 *  Plugin Contributor [gidomanders](https://wordpress.org/support/users/gidomanders/)
 * (@gidomanders)
 * [7 years, 10 months ago](https://wordpress.org/support/topic/amazon-cloudfront-invalidations/#post-10539299)
 * [@hileon](https://wordpress.org/support/users/hileon/) I’m very sorry that we’re
   causing such bills. We’re working on an option to only send invalidation requests
   when you click the purge button and we’ll add a notification about the possible
   costs of invalidation requests when that option is not enabled.
 *  [fireflake](https://wordpress.org/support/users/fireflake/)
 * (@fireflake)
 * [7 years, 8 months ago](https://wordpress.org/support/topic/amazon-cloudfront-invalidations/#post-10652191)
 * We did a rebuild thumbnail which I had no clue was linked with these invalidations.
   We had 48 564 invalidations which has so far cost us $237.82. There where numerous
   similar invalidations over the past few months but not of this magnitude which
   caused it to pass by unnoticed.
 * I see no option anywhere in W3 cache to disable this feature and I originally
   thought it was only triggered by manual cache purge.
 * [@gidomanders](https://wordpress.org/support/users/gidomanders/) how is the updated
   feature of invalidations coming? Is there a way to disable invalidations permanently?
 *  Plugin Contributor [gidomanders](https://wordpress.org/support/users/gidomanders/)
 * (@gidomanders)
 * [7 years, 8 months ago](https://wordpress.org/support/topic/amazon-cloudfront-invalidations/#post-10652223)
 * [@fireflake](https://wordpress.org/support/users/fireflake/) Unfortunately we’re
   not able to get the feature to only invalidate on purge ready for the upcoming
   release. That release will be a minor release, v0.9.7.1. The feature is listed
   for v0.9.8 though, so you guys have to stay tuned for a bit longer.
 * As I suggested before, as a temporary fix, use the generic mirror option for 
   CDN. That way no invalidation requests will be sent.
 *  [fireflake](https://wordpress.org/support/users/fireflake/)
 * (@fireflake)
 * [7 years, 8 months ago](https://wordpress.org/support/topic/amazon-cloudfront-invalidations/#post-10652330)
 * [@gidomanders](https://wordpress.org/support/users/gidomanders/) Thank you for
   a quick response and heads up!
 * I have changed to generic mirror CDN now and hopefully we will see an effect 
   of this change on our upcoming AWS bill! 🙂
 *  [andrewfitz](https://wordpress.org/support/users/andrewfitz/)
 * (@andrewfitz)
 * [7 years, 7 months ago](https://wordpress.org/support/topic/amazon-cloudfront-invalidations/#post-10744704)
 * I never get outraged, but this is crazy.
 * You add a feature that can’t be turned off that causes thousands of dollars of
   charges to users without telling them? I just spent hours figuring out why my
   bill was so high, and it was due to these invalidations. I’m lucky to have caught
   it.
 * Do you have any idea how unethical this is? The person above said it cost him
   $6000… that’s insane. I mean literally **hundreds of thousands of dollars** if
   not more this is costing people that have no idea. And 4 months to fix this? 
   Not even yet?
 * Have you emailed users or notified AWS? You guys have over a million users. I
   understand people make mistakes and this is a free plugin without warranty, but
   this needs to addressed publicly so at least people know.
 *  Plugin Contributor [gidomanders](https://wordpress.org/support/users/gidomanders/)
 * (@gidomanders)
 * [7 years, 7 months ago](https://wordpress.org/support/topic/amazon-cloudfront-invalidations/#post-10746760)
 * [@andrewfitz](https://wordpress.org/support/users/andrewfitz/), of course we 
   don’t want anyone to be frustrated. There are a few important things to remember:
    1. There are various other providers that you can use for free or lower cost than
       AWS until the fix is I also commented as temporary solution to use generic mirror.
    2. The functionality as it works today has been that way for quite some time and
       the reports from end users of issues is very low, which determines the priority
       of changes. Changes take time and must be tested.
    3. We have very little data on how our software is used and by whom, so the few
       people who’ve pointed this issue out are vocal because they’re investing heavily
       in their sites.
    4. As for making releases more frequent, we’ve been supportive of forks and contributions
       from the community to address issues that are important to them. The community
       has not prioritized this fix given the amount of control and alternative options
       available. AWS has always been among the more expensive providers in the market.
 *  [nitin35](https://wordpress.org/support/users/nitin35/)
 * (@nitin35)
 * [7 years, 6 months ago](https://wordpress.org/support/topic/amazon-cloudfront-invalidations/#post-10909854)
 * I agree with andrew here. Your plugin is causing so much monetary loss to your
   users and still you are not prioritizing this important issue for the past so
   many months. Users will only realize this issue after they get a bill shock.
 * The feature which causes this bill shock is not even important. Your plugin is
   calling for an invalidation immediately after an image is uploaded, it wont even
   be in the CDN cache at that time, where’s the need for invalidation. You can 
   always provide a setting to disable automatic invalidation from your plugin and
   put a button for manual invalidation.
 * Please take this issue on priority. If each one of the effected people start 
   giving a 1 star review on wordpress then I am sure you’ll notice the seriousness
   and take it on priority.
 *  Plugin Contributor [gidomanders](https://wordpress.org/support/users/gidomanders/)
 * (@gidomanders)
 * [7 years, 6 months ago](https://wordpress.org/support/topic/amazon-cloudfront-invalidations/#post-10921790)
 * [@nitin35](https://wordpress.org/support/users/nitin35/)
    - I found and fixed the problem with new uploads being invalidated, so the new
      release will not be sending invalidation requests for new uploads anymore.
    - We’ve also added an option `Purge only manually` to control CDN purging yourself
      instead of automatically.
 * These will give users more control over CDN purging, thus how many invalidation
   requests are sent to CloudFront.
 *  [fingolfinn](https://wordpress.org/support/users/fingolfinn/)
 * (@fingolfinn)
 * [7 years, 4 months ago](https://wordpress.org/support/topic/amazon-cloudfront-invalidations/#post-11116449)
 * When does this fix get released into the product? The currently Version: 0.9.7
   is 9 months old. Is there a patched file we can get?
 * We are experiencing this problem as well. Cost us $123 last month.

Viewing 15 replies - 1 through 15 (of 23 total)

1 [2](https://wordpress.org/support/topic/amazon-cloudfront-invalidations/page/2/?output_format=md)
[→](https://wordpress.org/support/topic/amazon-cloudfront-invalidations/page/2/?output_format=md)

The topic ‘Amazon Cloudfront Invalidations’ is closed to new replies.

 * ![](https://ps.w.org/w3-total-cache/assets/icon-256x256.png?rev=1041806)
 * [W3 Total Cache](https://wordpress.org/plugins/w3-total-cache/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/w3-total-cache/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/w3-total-cache/)
 * [Active Topics](https://wordpress.org/support/plugin/w3-total-cache/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/w3-total-cache/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/w3-total-cache/reviews/)

## Tags

 * [CloudFront](https://wordpress.org/support/topic-tag/cloudfront/)
 * [W3TC](https://wordpress.org/support/topic-tag/w3tc/)

 * 23 replies
 * 13 participants
 * Last reply from: [gjones604](https://wordpress.org/support/users/gjones604/)
 * Last activity: [7 years, 1 month ago](https://wordpress.org/support/topic/amazon-cloudfront-invalidations/page/2/#post-11389152)
 * Status: not resolved