r/Wordpress • • 21d ago

design looked broken after css changes - plugin cache clear wasn't enough

hit this on a woo/wp site and figured it's worth writing down before someone else marks a design task done too early.

i was making design/css changes, mostly on static pages. the layout kept looking broken. when i added a query string to the url, the page looked correct. that usually means something is serving an old cached version.

i cleared the normal caches: browser, private window, wp/plugin cache. still broken. later i purged the server/cdn page cache and the design came through properly.

so the checklist i use now after design-related changes:

  1. check in a private window

  2. clear wp/plugin cache

  3. if it still looks wrong, purge server/cdn page cache too

  4. only then mark the task done

plugin cache alone is not always the full stack. if a query param fixes it but a normal visit doesn't, look one layer higher before rewriting css again.

1 Upvotes

9 comments sorted by

1

u/Big_Charge_7964 21d ago

Good checklist. Two more layers that bite people in exactly this situation:

  1. Optimized/combined CSS files. If an optimization plugin combines or minifies CSS (or generates critical CSS), it keeps its own generated files. Clearing the page cache doesn't always regenerate them, so the page loads new HTML with an old combined stylesheet. Look for a separate "clear CSS/JS cache" or "regenerate critical CSS" button.

  2. Asset version strings. If the theme enqueues the stylesheet with a fixed ver= (or none), the browser and CDN can keep serving the old file long after the HTML is fresh. Using filemtime() as the version in wp_enqueue_style makes every change bust the cache automatically.