Speed · medium impact

WooCommerce scripts load on non-shop pages

WooCommerce's CSS and JavaScript are loading on this page even though it isn't a shop, product, cart or checkout page.

Why it matters

Blog posts and landing pages pay for e-commerce code they never use: extra render-blocking CSS and JavaScript the browser has to parse.

How to fix it in WordPress

  1. Use a script manager to disable WooCommerce styles and scripts on pages that aren't part of the store.
  2. Keep them enabled on shop, product, cart, checkout and account pages, and anywhere you use WooCommerce blocks or shortcodes.
  3. Clear your page cache.

Plugin-specific steps

Already using one of these plugins? Follow the exact steps for your setup.

Perfmatters

  1. 1Go to Settings → Perfmatters → General → WooCommerce.
  2. 2Toggle on 'Disable Scripts' — Perfmatters keeps them on WooCommerce pages automatically.
  3. 3Optionally toggle on 'Disable Widgets' if you don't use WooCommerce widgets.
  4. 4Save and clear your cache.

How to verify the fix

  • Load a blog post and confirm no /plugins/woocommerce/ files are requested.
  • Load a product page and confirm the gallery, variations and add-to-cart still work.

Be careful

  • If you show products on non-shop pages (blocks, shortcodes, sliders), keep WooCommerce assets enabled on those pages.

Find out which of these your site has.

Free scan with real Google data. Exact fixes for your plugins.