
WooCommerce stores are slower than normal WordPress sites because carts, checkouts and account pages are dynamic and cannot be fully cached, and large catalogues create heavy database queries. To speed up WooCommerce: use hosting with enough CPU and RAM, enable page caching with the right exclusions, add Redis object caching, turn on High-Performance Order Storage (HPOS), stop cart fragments loading on every page, optimise product images, cut plugins and scripts, and keep the database clean. Also, this guide explains each step in the order that usually gives the biggest gains. This guide explains WooCommerce speed optimization step by step.
- Cache product, category and content pages; never cache cart, checkout or my-account.
- Redis object caching speeds up the uncached pages, including the admin.
- HPOS stores orders in dedicated tables and is the default for new stores.
- Measure before and after with PageSpeed Insights and Query Monitor.
Step 1: Measure your WooCommerce speed first
- Test the home page, a category page, a product page and the cart with PageSpeed Insights (mobile). See how to check website speed.
- Install Query Monitor temporarily to see slow database queries, PHP errors and which plugins add the most time.
- Check server response time (TTFB). If uncached pages take over a second to start, the server or database is the bottleneck.
Step 2: Hosting that fits a store
Stores need more resources than brochure sites. Then look for LiteSpeed or Nginx, PHP 8.2 or newer, Redis availability, and enough RAM (2 to 4 GB or more for an active store). Shared hosting that is fine for a 10-page site often struggles once orders and customers grow. Our hosting comparison explains the options. Also, this matters for WooCommerce speed optimization on every kind of site.
Step 3: Page caching with WooCommerce exclusions
Then use LiteSpeed Cache (on LiteSpeed servers), WP Rocket, or your host's cache. Make sure these are excluded from page cache:
/cart/*
/checkout/*
/my-account/*
/?add-to-cart=*
/wp-json/wc/*
Cookies: woocommerce_items_in_cart, woocommerce_cart_hash, wp_woocommerce_session_*
Good caching plugins detect WooCommerce and add these automatically; check anyway. Logged-in customers usually bypass the cache, which is why object caching matters.
Step 4: Redis object caching
Object caching stores the results of database queries in memory, speeding up uncached pages, search, filters and the admin. Enable Redis in your hosting panel or on your VPS, then install a connector plugin (Redis Object Cache, or the object cache option in LiteSpeed Cache). Verify the "Connected" status. Add to wp-config.php if your host asks for a unique prefix:
define( 'WP_CACHE_KEY_SALT', 'example.com:' );
Step 5: Enable HPOS
High-Performance Order Storage moves orders out of the general WordPress posts tables into dedicated order tables, making order queries and admin screens faster. It is the default for new stores since WooCommerce 8.2. For older stores, go to WooCommerce → Settings → Advanced → Features, enable compatibility mode to sync data, check that all your plugins are HPOS-compatible, then switch to HPOS. Take a backup first.
Step 6: Stop cart fragments on every page
The cart fragments script (wc-cart-fragments) makes an uncached AJAX request on page loads to update the mini cart. Since WooCommerce 7.8 it only loads where the Mini Cart block is used, but many classic themes still enqueue it everywhere. If your header does not show a live cart count, disable it on non-shop pages with your performance plugin, or:
add_action( 'wp_enqueue_scripts', function () {
if ( ! is_cart() && ! is_checkout() && ! is_woocommerce() ) {
wp_dequeue_script( 'wc-cart-fragments' );
}
}, 20 );
Step 7: Product images that keep WooCommerce speed high
- Upload images at a sensible size (around 1200 to 1600 px on the longest side) and compress them. See our product image size guide.
- Serve WebP or AVIF; see converting to WebP.
- Set WooCommerce thumbnail sizes in Appearance → Customize → WooCommerce → Product Images to match your theme, then regenerate thumbnails.
- Lazy-load grid images after the first row, but not the main product image. See our lazy loading guide.
Step 8: Cut plugins and scripts that hurt WooCommerce speed
- Remove plugins you do not use, and replace heavy multi-purpose plugins with lighter single-purpose ones.
- Unload plugin CSS and JS on pages that do not need them, for example review widgets on blog posts.
- Limit tracking scripts; several pixels plus live chat can damage INP on product pages.
- Heavy product filters and "live search" plugins can generate expensive queries; test them with Query Monitor.
Step 9: Keep the database clean
- Clear expired transients and old sessions (WooCommerce → Status → Tools).
- Clean completed Action Scheduler entries (WooCommerce → Status → Scheduled Actions); on large stores this table can grow to millions of rows.
- Limit post revisions:
define( 'WP_POST_REVISIONS', 10 ); - Check that the
wp_optionsautoloaded data stays small; Site Health warns if it is too large.
Step 10: Improve checkout speed in WooCommerce
- Remove unnecessary checkout fields, which reduces both load and abandoned checkouts.
- Load payment gateway scripts only on checkout.
- Consider the block-based Checkout, which is lighter in many setups; test it with your gateways, including JazzCash and Easypaisa plugins (see our payment gateway guide).
WooCommerce speed: frequently asked questions
WooCommerce speed: why is my WooCommerce admin so slow?
Usually a lack of object caching, large Action Scheduler or options tables, or plugins running heavy queries on every admin page. Query Monitor shows the cause.
Can I cache the cart page with a CDN?
No. Cart and checkout are personal to each visitor; caching them would show one customer's cart to another.
How many products can WooCommerce handle?
Tens of thousands with good hosting, HPOS, object caching and a lean plugin set.
Related guides: Shopify vs WooCommerce in Pakistan, Why Website Speed Matters and How to Make Your Site Faster and How to Speed Up a WordPress Website.
For official guidance, see the official WordPress documentation.
Want a faster store?
Our speed optimization and e-commerce teams tune WooCommerce stores for speed and conversions. Contact us.
Written by the ItsWebExpert team, a web design and development company in Karachi building websites, online stores and apps for businesses across Pakistan.
Ask a Question on WhatsApp