Variable Products
Last updated
Last updated
Variable products in WooCommerce let you offer a set of variations on a product, with control over prices, stock, image and more for each variation. They can be used for products like shirts and shoes, where you can offer a large, medium and small and in different colors.
To add a variable product, create a new product or edit an existing one.
Go to: WooCommerce > Products.
Select the Add Product button or Edit an existing product. The Product Data displays.
Select Variable product from the Product Data dropdown.
In the Attributes section, add attributes before creating variations — use global attributes that are site-wide or define custom ones specific to a product.
To use a global attribute on your product:
First create a global attribute.
Then you can choose said global attribute from the dropdown and select Add.
Choose Select all to add all values from to the variable product (if applicable).
Most importantly select the Used for variations checkbox to use these for variations.
Select Save attributes.
Custom Attributes
To add a new attribute specific to this product:
Select Custom product attribute and click Add.
Name the attribute (e.g., Size).
Set values separated by a vertical pipe, |
(e.g., Small | Medium | Large).
Make sure that the Used for variations checkbox is checked. (Note: If your creating the first attribute for the variable product, it can also be done from the “Variations” tab. However, here the “Used for variations” checkbox will be checked and cannot be disabled)
Select Save attributes.
With attributes created and saved to add a variation, go to the Variations section in the Product data meta box.
Manually Add a Variation
Select Add variation from the dropdown menu, and select Go.
Select attributes for your variation. To change additional data, click the triangle icon to expand the variation.
Edit any available data. The only required field is Regular Price.
Select Save changes.
Creating All Possible Variations
Select Create variations from all attributes to have WooCommerce create every possible combination of variations from your attributes and their values and select Go:
It will create a new variation for each and every possible combination of variation attributes. For example, if you have two attributes – color (with values blue and green) and size (with values large and small) it creates the following variations:
Large Blue
Large Green
Small Blue
Small Green
Note: If you later add additional attributes, it may require the variables to be redefined for the variation combinations to work correctly.
If you have more than 15 variations, use the buttons to navigate forward and backward through the list. Each time you navigate to a new set of variations, the previous set is saved. This ensures that all changes are saved.
If you want a certain variation already selected when a user visits the product page, choose the default form values. This also enables the Add to Cart button to appear automatically on variable product pages.
Please note that setting default form values on variations may affect the original display on the product page. Look for web developer if you need assistance.
The variation data is basically the same as you can see from other product types.
Сhoose how to manage stock by toggling Enable stock management at product level on the Inventory tab:
Set Stock Status can be applied to all variations at once to In stock or Out of stock. Bulk-update under Variations:
If the SKU, weight, dimensions, and stock fields are not set, then it inherits values assigned to the variable product. Price fields must be set per variation.
Expand the variation.
Click the blue image placeholder (screenshot).
Select the image you wish to use.
Save.
You can bulk-edit variations by selecting the specific piece of data you want from the dropdown. In this example, I want to edit prices for all variations:
On the frontend, when viewing a variable product, the user is presented with dropdown boxes to select variation options. Selecting options will reveal information about the variation, including available stock and price.
Note: This is just a general example/demo, the display of the variation options could be different due to different designs and layouts of your website.