Title: Using W3TC / AWS Cloudfront
Last modified: April 4, 2019

---

# Using W3TC / AWS Cloudfront

 *  Resolved [csbwebmaster](https://wordpress.org/support/users/csbwebmaster/)
 * (@csbwebmaster)
 * [7 years, 2 months ago](https://wordpress.org/support/topic/using-w3tc-aws-cloudfront/)
 * Hi friends:
 * I’m new to W3TC. Been using it for a couple weeks. Finally took the plunge and
   setup Cloudfront as a CDN.
 * When I run GTMETRIX or PINGDOM, both report that there are multiple redirects
   happening on my images. It is also saying that I’m getting an ‘F’ (on Pingdom)
   ADD EXPIRES HEADER, yet it looks like I have Cloudfront to expire content.
 * Can someone advise please? Why is it saying that I don’t have EXPIRES headers?
   What do I need to configure in W3TC to set this? Or is there something else in
   Cloudfront?
 * The page I need help with: _[[log in](https://login.wordpress.org/?redirect_to=https%3A%2F%2Fwordpress.org%2Fsupport%2Ftopic%2Fusing-w3tc-aws-cloudfront%2F%3Foutput_format%3Dmd&locale=en_US)
   to see the link]_

Viewing 4 replies - 1 through 4 (of 4 total)

 *  Thread Starter [csbwebmaster](https://wordpress.org/support/users/csbwebmaster/)
 * (@csbwebmaster)
 * [7 years, 2 months ago](https://wordpress.org/support/topic/using-w3tc-aws-cloudfront/#post-11392590)
 * Ok, I have worse problem now none of my images are coming from the CDN.
 * I feel so over my head on this one. Going to turn off w3tc
 *  Thread Starter [csbwebmaster](https://wordpress.org/support/users/csbwebmaster/)
 * (@csbwebmaster)
 * [7 years, 2 months ago](https://wordpress.org/support/topic/using-w3tc-aws-cloudfront/#post-11393320)
 * Just a quick note, I figured out partly that it was the W3TC minify feature that
   was causing my layouts to be pooched (including missing images).
 * Turned that off and instead used a different minification plug in and at least
   my site is back to normal in terms of visibility and proper display now.
 * Phew!
 *  Plugin Contributor [Marko Vasiljevic](https://wordpress.org/support/users/vmarko/)
 * (@vmarko)
 * [7 years, 2 months ago](https://wordpress.org/support/topic/using-w3tc-aws-cloudfront/#post-11393852)
 * Hello,
 * I’ve tested your website on GTmetrix. Great score by the way. If you take a closer
   look at Add Expires headers, it showing third-party resources that we do not 
   have any control over.
 *  Thread Starter [csbwebmaster](https://wordpress.org/support/users/csbwebmaster/)
 * (@csbwebmaster)
 * [7 years, 2 months ago](https://wordpress.org/support/topic/using-w3tc-aws-cloudfront/#post-11395831)
 * Thank you. I’ve been working hard to get it optimized.
 * We are a very tiny non-profit and usually get little web traffic. Recently, we
   had an event where 400 near simultaneous users attempted to access the site to
   sign up for registration (a WPFORM). I was surprised to see that the hosting 
   provider (AWS lightsail) couldn’t handle it. So I’ve been doing everything possible
   to optimize, including implementing our first CDN.
 * Thanks for the reply, BTW. I really don’t do a lot of WP for scale…mostly small
   sites. But I used to be a Director doing enterprise infrastructure, and designing
   for scalability was my thing back then.
 * I’ve a few things to figure out yet with Cloudfront/W3TC: Does purge trigger 
   a purge of Cloudfront or just the Apache servers (W3TC/WP) cache?
 * Is there a way to add versioning to file names or assets with a plugin so that
   updated assets published are newly populated to Cloudfront? (We use BigCommerce.
   When files are uploaded into their media library, they all get an asset link 
   with a version that helps ensure refreshed assets are used.
 * How do I ensure old/unused assets are dropped out of cloudfront or doesn’t that
   matter?
 * How can I ensure that Cloudfront helps RE: DDOS and other threats.
 * I was going to look into Cloudflare, but chose not to for quite a few reasons
   that I won’t get into here. But besides my main requirement (scalability, asset
   caching), is protection. I’ve not yet figured that out with CLoudfront.
 * These are some things I’m still working on. I’m also trying to do some load testing
   using jmeter (I don’t have access to LoadRunner) to test the newly CDN-optimized
   site for scale. I’m sure we won’t really get much in the way of traffic anytime
   soon. But I’m hoping the recent reconfiguration, use of W3TC/Cloudfront, gives
   me a bit more scale. I don’t know how AWS Lightsail can be boosted (if at all)
   given load/demand. I don’t know that it’s fixed or scalable as a service.
 * Anyways, thanks for the reply. Got some more to do yet. But it’s improving.

Viewing 4 replies - 1 through 4 (of 4 total)

The topic ‘Using W3TC / AWS Cloudfront’ 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/)

 * 4 replies
 * 2 participants
 * Last reply from: [csbwebmaster](https://wordpress.org/support/users/csbwebmaster/)
 * Last activity: [7 years, 2 months ago](https://wordpress.org/support/topic/using-w3tc-aws-cloudfront/#post-11395831)
 * Status: resolved