Keeping a WooCommerce store with hundreds of product variations easy to shop

Above 30 variations, WooCommerce changes how product pages work. What goes wrong at scale and how to keep large variable products fast and easy to buy.

WooCommerce variable products work well with a handful of options. A T-shirt in four sizes and three colours is twelve variations, and the default product page handles it fine. Add a third attribute and a few more values, and you can be into hundreds of variations on one product. That’s when the admin slows to a crawl, the product page takes seconds to respond, and customers can’t work out which combinations exist.

Here’s what goes wrong at scale and what I change to keep large variable products fast and easy to buy.

The 30-variation threshold

When a variable product has 30 variations or fewer, WooCommerce prints all of them into the page as JSON. The front end then knows every combination’s price, stock and image instantly, and can grey out options that don’t exist.

Above 30, it stops doing that. Instead, each time the customer finishes choosing options, the page makes an AJAX request to ask whether that combination exists. That has two visible effects:

  • There’s a short delay after every selection while the request completes.
  • The dropdowns can no longer hide or disable combinations that don’t exist, so customers pick something, then get told it’s unavailable.

The threshold is filterable:

add_filter( 'woocommerce_ajax_variation_threshold', function ( $threshold, $product ) {
	return 150;
}, 10, 2 );

Raising it brings back instant feedback, at the cost of a bigger page. Each variation adds a few hundred bytes of JSON, so 150 variations might add 40–60 KB. That’s worth it for a product where choosing the right option is the buying decision. It isn’t worth it for 2,000 variations. Measure the page weight before and after, and set the threshold per product type if you need to.

Design the choice, not just the dropdowns

Three dropdowns in a row is the default, and it’s rarely the best way to pick from hundreds of combinations. A few changes help a lot:

  • Order attributes by how people decide. If customers choose size first and colour second, put size first. The first choice should narrow the rest.
  • Swatches or buttons instead of dropdowns for attributes with a few values, so every option is visible at once.
  • Show what changes. When a choice changes the price, the image, the delivery time or the specification, update it straight away, next to the options.
  • Explain the unavailable. “Not available in this size” is better than an option that silently does nothing.

Specification-heavy products

On products where each variation has its own dimensions, weights or materials, the specification table often matters more than the photo. Store per-variation specs as variation meta, then render one table and update its cells when the variation changes, rather than printing a full table for every variation:

jQuery('form.variations_form').on('found_variation', (event, variation) => {
  document.querySelectorAll('[data-spec]').forEach((cell) => {
    const key = cell.dataset.spec;
    cell.textContent = variation.specs?.[key] ?? cell.dataset.default;
  });
});

The found_variation event fires with the variation’s data whenever a valid combination is chosen. Add your own data to that payload server-side:

add_filter( 'woocommerce_available_variation', function ( $data, $product, $variation ) {
	$data['specs'] = array(
		'width'  => $variation->get_meta( '_spec_width' ),
		'weight' => $variation->get_meta( '_spec_weight' ),
	);
	return $data;
}, 10, 3 );

Keep the admin usable

Large variable products are also painful to edit. The variations panel loads them in pages (15 at a time by default), and saving can time out on shared hosting. A few things make it bearable:

  • Set defaults at the product level where you can, such as tax class and shipping class, so variations only hold what actually differs.
  • Use bulk edit and CSV import for prices and stock rather than editing variations one by one. WooCommerce’s built-in importer handles variations.
  • Consider splitting the product. If one attribute effectively creates separate products, like a garden building in three different materials, they may be better as three products linked together. Shoppers often compare them that way anyway.

Category pages with attribute filters (“show me everything available in 3m × 3m”) need to know which variations are in stock. Recent WooCommerce versions keep a product attributes lookup table for exactly this. Make sure it’s enabled and regenerated (WooCommerce → Settings → Products → Advanced), or filtering by attribute on a large catalogue will be slow and sometimes wrong.

Performance checklist

  • Measure the product page’s HTML size and Time to First Byte before changing anything.
  • Raise the variation threshold where instant feedback matters, and check the page weight afterwards.
  • Load variation images at a sensible registered size, not full resolution.
  • Cache product pages, but exclude cart and checkout.
  • Keep the attributes lookup table up to date.

Large catalogues are where WooCommerce needs the most care, and where good choices make the biggest difference to sales. It’s the kind of WooCommerce work I enjoy most.

Written by

James Knowles

Started in 2021 as an apprentice on a support desk, answering clients directly, then worked through agency teams on WordPress, WooCommerce and Shopify builds. Now leads Ramosa and every project.

More from James

Got a WordPress project?