Selling a T-shirt in three sizes and five colours? A phone case compatible with six models? A coffee subscription in three frequencies?
These are all variable products in WooCommerce — single products that come in multiple variants, each potentially with different pricing, stock levels, images, and availability.
Setting up WooCommerce product variations correctly is one of the most important skills for store owners who sell products with options. Done well, it creates a clean, professional shopping experience. Done poorly, it creates confusion, cart abandonment, and inventory headaches.
This step-by-step guide covers everything — from creating attributes to managing stock per variation, setting up variation-specific images, and handling edge cases.
Understanding WooCommerce Variable Products
Before diving into setup, understand the key concepts:
- Attributes — The characteristics that vary between versions of a product. Examples: Size, Colour, Material, Model Compatibility.
- Attribute values (Terms) — The specific options within each attribute. Size values: Small, Medium, Large, XL. Colour values: Red, Blue, Green.
- Variations — The individual purchasable combinations of attributes. A product with Size (S, M, L) and Colour (Red, Blue) has 6 possible variations: S-Red, S-Blue, M-Red, M-Blue, L-Red, L-Blue.
- Global attributes — Attributes defined in WooCommerce → Attributes that can be reused across multiple products. Best for attributes you use on many products (Size, Colour).
- Custom attributes — Attributes defined on a specific product only. Good for attributes unique to one product.
01
Create Global Attributes
For attributes you'll use across multiple products (Size, Colour), create global attributes first. This saves time and enables filtering on your shop pages.
- Go to Products → Attributes
- Fill in:
- Name: Size
- Slug: size (auto-generated, leave it)
- Enable archives: Check this to allow filtering products by this attribute on the shop page
- Click Add attribute
- Next to your new attribute, click Configure terms
- Add each value: Small, Medium, Large, XL, XXL — click Add new Size for each
- Repeat for Colour: Add attribute "Colour" → Configure terms: Red, Blue, Green, Black, White
Your global attributes are now ready to use on any product.
02
Create a Variable Product
- Go to Products → Add New
- Enter your product title, description, and images as usual
- In the Product Data section, change the dropdown from "Simple product" to "Variable product"
The product data tabs will change to show Attributes and Variations tabs.
03
Add Attributes to the Product
- Click the Attributes tab in Product Data
- In the "Add attribute" dropdown, select "Size" (your global attribute) → Click Add
- In the Size attribute row:
- Click the Values field and select the sizes relevant to this product (Small, Medium, Large)
- Check "Used for variations" — this is critical, it enables these attributes to generate variations
- Check "Visible on the product page" — shows the attribute in product specifications
- Repeat for Colour — add Colour attribute, select relevant colours, check "Used for variations"
- Click Save attributes
Critical: If you forget to check "Used for variations," WooCommerce won't generate variations from that attribute. This is the most common mistake in variation setup.
04
Generate Variations
- Click the Variations tab
- From the action dropdown, select "Create variations from all attributes"
- Click Go
- Click OK when prompted — WooCommerce generates all possible combinations
For Size (S, M, L) × Colour (Red, Blue, Black), WooCommerce generates 9 variations:
S-Red, S-Blue, S-Black, M-Red, M-Blue, M-Black, L-Red, L-Blue, L-Black
05
Configure Each Variation
Each variation appears as an expandable row. Click the arrow to expand a variation and configure:
Price (required)
- Regular price: Standard price for this variation
- Sale price: Optional discounted price with optional date range
You can set different prices for different variations — e.g., Small T-Shirt: ₹499, Medium: ₹499, Large: ₹549 (if larger sizes cost more to produce).
SKU
Enter a unique SKU per variation (e.g., TSHIRT-RED-S, TSHIRT-RED-M). This is your internal stock keeping code and should be unique for each variation.
Stock Management
- Check "Manage stock?" for individual variation stock tracking
- Enter "Stock quantity" — the number of units you have
- Set "Allow backorders" if applicable
- Stock status is managed automatically based on quantity
Shipping
Weight and dimensions per variation (if they vary — important for size-based shipping calculations).
Image
Click the image icon to assign a specific product image to this variation. When a customer selects "Red", they see the red product image. This is crucial for colour variations and dramatically improves the shopping experience.
Variation Description
Optional short description specific to this variation — can highlight unique features or notes.
After configuring, scroll down and click Save changes.
06
Set a Default Variation
WooCommerce can pre-select a variation when the product page loads. Go to Attributes tab → "Default values" section → Select your default attribute values.
Example: Default to Size: Medium, Colour: Black — the product page loads with these options pre-selected. Choose your most popular combination.
Why this matters: A pre-selected default variation means customers see a price and an "Add to Cart" button immediately — instead of a "Please select an option" message that creates friction.
Managing Variation Images
Variation images significantly improve the shopping experience — particularly for colour variations.
Best practices:
- Use consistent image dimensions for all variation images (square, same resolution)
- Photograph or render every colour/style variant available
- Name image files descriptively before uploading:
red-tshirt-front.jpg, blue-tshirt-front.jpg
When a customer selects a variation, the product's main image automatically switches to the variation's assigned image — no JavaScript customisation required.
Handling Stock Per Variation
Individual Variation Stock Management
For most stores, tracking stock per variation is essential — you may have 50 Medium-Red but only 10 Small-Blue.
In each variation: Check "Manage stock?" → Enter current stock quantity → WooCommerce automatically marks a variation as "Out of stock" when quantity reaches zero.
Product-level stock vs. variation-level stock:
- If you enable "Manage stock?" at the product level (Product Data → Inventory), all variations share that stock pool
- If you enable "Manage stock?" at the variation level, each variation has independent stock
- For most variable products, variation-level stock is more accurate
Out of Stock Variations
When a variation runs out of stock, WooCommerce marks it as "Out of stock" and disables the option in the variation selectors (greyed out). It can also hide it entirely — configured in WooCommerce → Settings → Products → Inventory → "Out of stock visibility".
Low Stock Notifications
Configure low stock alerts per product: Product Data → Inventory → "Low stock threshold" — WooCommerce emails the store admin when stock reaches this level.
Advanced Variation Techniques
Bulk Edit Variation Prices
For products with many variations, editing each one individually is tedious. WooCommerce provides bulk editing:
- In the Variations tab, select "Set regular prices" from the bulk actions dropdown
- Enter a price → Click Go — sets all variations to the same price
- Or use "Increase regular prices by (fixed amount or %)" to add a consistent markup
Variation Swatches (Visual Enhancement)
Replacing dropdown selectors with visual swatches dramatically improves UX:
- Variation Swatches for WooCommerce (free) replaces Size dropdown with button labels and Colour dropdown with colour circles
- Images assigned to each attribute term in Products → Attributes → Configure terms become swatch images
Ajax Variation Loading for Large Products
Products with more than ~50 variations can cause performance issues. WooCommerce loads all variation data as JSON on the product page. For products with many variations, increase the Ajax loading threshold:
// Increase variation threshold for Ajax loading
add_filter( 'woocommerce_ajax_variation_threshold', function() {
return 100; // default is 30
});
Troubleshooting Common Variation Problems
- "Please select an option" — variation not selectable: Check that "Used for variations" is checked for each attribute in the Attributes tab.
- Variation shows correct price but cart adds the wrong variation: Clear your browser cache and site cache. A cached page may be serving stale variation data.
- Out-of-stock variations still appear selectable: Go to WooCommerce → Settings → Products → Inventory and check "Hide out of stock items from the catalog" or ensure variation-level stock management is enabled.
- Variation images not switching on attribute selection: Verify each variation has an image assigned (not just the parent product). The image must be assigned at the variation level, not just in the product gallery.
- Too many variations causing slow product pages: Use the Ajax variation threshold filter above, or consider reducing the number of active attribute combinations.
Frequently Asked Questions
Q: Is there a limit to how many variations a WooCommerce product can have?
A: WooCommerce has a soft limit of 50 variations by default before AJAX loading kicks in. Technically, you can have hundreds of variations, but performance degrades significantly above ~200 variations on standard hosting. For very large product configurations, consider using "custom options" plugins that handle selections differently.
Q: Can I have a variation with no price?
A: Every variation needs a price to be purchasable. Variations without prices are displayed as "Not yet set" in the admin — customers can't add them to cart.
Q: How do I add a new variation attribute value after the product is published?
A: Go to Products → Attributes → Configure terms for the relevant attribute, add the new value (e.g., "XXL" to Size), then return to the product and update the attribute to include the new value. Then generate the new variation(s) in the Variations tab.
Final Thoughts
WooCommerce variable products are one of the platform's most powerful features — enabling you to sell complex products with multiple options while maintaining clean inventory management per variation. The setup process takes 20–30 minutes for a product with a handful of attributes, and the result is a professional shopping experience that meets customer expectations.
The keys to success: assign images to every variation (especially colours), manage stock at the variation level for accuracy, and install variation swatches to replace clunky dropdowns with visual selectors.
Need help setting up complex WooCommerce variable products or customising the variation display? Our development team handles WooCommerce product setup and customisation.
Contact us today for WooCommerce development support