• Hello all,

    I am wondering if someone can point me in the right direction. I am using W3 total Cache as well as Autoptimize and so far the results have drastically improved my site. The problem I am faced with is google telling me that some of my static assets are using an inefficient cache policy. It appears limited to the home page.

    I have gone over all the settings I can find in both plugins and I see no sign of why this is happening. I made sure the “Don’t cache front page” option was unchecked so I assumed that would take care of the problem but the cache policy is still 7 days. Can someone offer any advice on what I may be doing wrong? I would very much appreciate any pointers. TIA

    The page I need help with: [log in to see the link]

Viewing 5 replies - 1 through 5 (of 5 total)
  • The problem I am faced with is google telling me that some of my static assets are using an inefficient cache policy.

    what resources are singled out @sdawales? or those files on your own domain or on 3rd party servers. if the latter there’s not much you can do I’m afraid. if on your own domain you might have to reconfigure your webserver to allow those assets to have a long cache-lifetime (typically with a .htaccess when on Apache).

    frank (ao dev)

    Thread Starter sdawales

    (@sdawales)

    Thanks for the response Frank. It’s for my own domain. It is basically my home page. All the images, ttf, css & js. I don’t know where it’s picking up the 7 days from. I thought that between W3 & autoptimize, that would allow me to set the cache for the homepage.

    Cheers.

    well, AO only sets cache lifetime for it’s own resources (and typically sets them for approx. 1 year), but that can be overwritten by the config in e.g. your root .htaccess. cache-ability of static assets is however not linked to how the HTML is cached by W3TC; the first is to be used by browsers to decide if they can use an existing version from cache, the 2nd is more about how (long) W3TC stores HTML on your server.

    Now i’ve compared cache lifetime of your logo between your homepage and “/configurator-car/” and in both cases the HTTP response header reads

    cache-control: max-age=604800, private which indeed is 7 days.

    so at first sight I don’t see a difference in the static resource cache-ability between your homepage and configurator-car.

    frank

    Thread Starter sdawales

    (@sdawales)

    Cheers Frank. Something else to get into…

    Thread Starter sdawales

    (@sdawales)

    Thanks again Frank. Was able to change the cache policy and all is now good. I appreciate the advice.

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘Uses inefficient cache policy on static assets’ is closed to new replies.