2

I use W3 Total Cache and CloudFlare (free-tier) as my CDN. For whatever reason, my WordPress site still caches the first version of its "Front Page" (not a posts page) for new user sessions, across all browsers and devices. After a few refreshes, though, the most recent front page is rendered. This behavior is still true in incognito.

I have tried the following things:

  • Setting CloudFlare to Developer Mode and dumping caches sitewide
  • Changing W3 Total Cache's setting to exclude caching both the post page and front page
  • Manually dumping W3 Total Cache's caches and setting it to dump caches whenever a post is made
  • Fetching as GoogleBot to see what it renders (PageSpeed Insights, this, and other fetches sometimes render the most recent variant and sometimes fetch the homepage from 6 months ago)
  • Debugging the site cache in inspect element via the Application tab (admittedly I don't really know what I'm looking for)

I host my site on a Digital Ocean droplet that is running an nginx stack and I'm stumped. How do I debug this kind of an issue?

1

First step, you should make sure that W3TC is the problem:

Check that pagespeed and varnish (and other cache you set with nginx) are working. - Disable W3TC and CDN, then check whether the caching problem persist. If the problem persist, you should check the nginx configuration and each cache settings and folders. The problem is not W3TC.

Install nginx helper plugin, this is also to make sure that you have correct nginx installation. Test your WP installation and make sure the PageSpeed cache and Varnish cache are doing their job. The cache folder usually on /var/cache.

If the problem is not appear, then try to turn on W3TC without CDN.

If W3TC is causing the problem, you need to check the installation procedure and changes you made in the nginx.conf and domain-available.conf Try to turn off all W3TC options, and turn it on one by one until problem happen again.

After that, you can turn on your CDN to check whether the CDN is the problem.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.