WebPagetest Forums
Question about Cache Static Content - Printable Version

+- WebPagetest Forums (https://www.webpagetest.org/forums)
+-- Forum: WebPagetest (/forumdisplay.php?fid=7)
+--- Forum: General Discussion (/forumdisplay.php?fid=25)
+--- Thread: Question about Cache Static Content (/showthread.php?tid=14955)



Question about Cache Static Content - M_Lyons10 - 06-30-2017 03:08 AM

Hello everyone!

I have been using WebPageTest over the last several weeks to try to speed up our website and had a question about Cache Static Content.

My site did not support this originally, but I just updated the web.config file (Windows hosting) to support Cache Static Content.

While I understand the usefulness of this, I noticed that it nearly doubled the time that my site takes to load... My site (as of this morning before the update) was loading in 2.57s, but after enabling Cache, it is loading in 4.19s. I have run several tests through WebPageTest and Chrome Developer Tools, and they are all fairly consistent.

Does Cache Static Content not always make sense? If my website is faster without it, is there really a benefit to having it enabled? Is there a benefit to our search rankings with Google and others to have this enabled anyway?

I am very curious what everyone thinks and if anyone knows why this would result in such a hit to performance. The website is a simple html site (with some css and javascript).

Thank you very much for your help!


RE: Question about Cache Static Content - GreenGecko - 06-30-2017 12:38 PM

Cache static content means just adding an expiry header to the relevant resources, so the browser in question knows to store them locally for that amount of time.

Adding an expiry header to a file should take a fraction of a microsecond, although I suppose the function of storing the file might take time...


RE: Question about Cache Static Content - M_Lyons10 - 07-01-2017 04:14 AM

(06-30-2017 12:38 PM)GreenGecko Wrote:  Cache static content means just adding an expiry header to the relevant resources, so the browser in question knows to store them locally for that amount of time.

Adding an expiry header to a file should take a fraction of a microsecond, although I suppose the function of storing the file might take time...

That's what I was thinking, but I am still seeing a significant hit to site speed.

To test this, I replaced the web.config file with the original (the only change was to enable cache static content) and the site speed went back to where it was before the web.config update.

I also ran the website update in two parts. First I uploaded the updated html files, etc. and conducted testing. Then, after the testing was completed, I uploaded the new web.config file and conducted a second round of testing. The difference in load time was significant!

I really don't understand why this would be, but it's definitely something I would like to resolve... It just doesn't make sense to me.