> For the complete documentation index, see [llms.txt](https://usermanual.ergonode.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://usermanual.ergonode.com/products/catalog/creating-new-product/product-with-variants.md).

# Product with variants

Set up a main product whose variants are simple products that differ in color, material or size, then generate the variants.

## Introduction

{% hint style="info" %}
A product with variants consists of a main product and simple products as its variants (similar to Magento configurable products).
{% endhint %}

If your product has multiple versions, such as colors, materials, or sizes, you will need a product with variants. To create one, follow the same initial steps as when creating a [simple product](https://usermanual.ergonode.com/products/catalog/creating-new-product/simple-products), but when you see the ***Create product*** popup window, choose ***Product with variants*** from the ***Product type*** drop-down.

<figure><img src="https://171427267-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FM9BbYBbDPiJapb75xJ2k%2Fuploads%2F0iYkrsapBLhWCiECSHiS%2Fimage.png?alt=media&#x26;token=8573a396-b5c4-4d59-a48f-9997f2d7b7b6" alt="" width="563"><figcaption></figcaption></figure>

Fill in the other fields the same way; choosing categories is optional, and the ***Category*** list works like the ***Category*** quick filter, described in [Quick filters](https://usermanual.ergonode.com/products/catalog/quick-filters). The differences will appear after you have created the product and moved to edit it. A ***Variants*** tab will become available, where you can select simple products to add.

<figure><img src="https://171427267-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FM9BbYBbDPiJapb75xJ2k%2Fuploads%2FFTaWEJaF04YUuA13jh7R%2F7a10e99bb587.png?alt=media&#x26;token=31f9198b-b765-487b-b3a3-a6a0b83a190e" alt=""><figcaption></figcaption></figure>

{% hint style="info" %}
The binding attribute is a common product attribute that links products together into a product with variants. The attribute must be of the SELECT type and have a GLOBAL scope.
{% endhint %}

Click on ***Add binding attributes*** (or on ***Binding attributes*** in the bar above the grid) to add a new one. A new window will appear.

<figure><img src="https://171427267-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FM9BbYBbDPiJapb75xJ2k%2Fuploads%2Fbg95R1yCgh8K7V97kDmn%2F09fd3ce73ede.png?alt=media&#x26;token=acb7bfbd-f4eb-4f02-9284-5597c367f794" alt="" width="563"><figcaption></figcaption></figure>

Click on ***Add binding attribute*** and add one or more. If you do not have a binding attribute available, you need to [create it first](https://usermanual.ergonode.com/product-design/attributes/create-a-new-attribute).

All added spaces for binding attributes must have an attribute selected before you can proceed.

<figure><img src="https://171427267-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FM9BbYBbDPiJapb75xJ2k%2Fuploads%2F5j0YMeBIHOmKpO43CbVO%2Fimage.png?alt=media&#x26;token=6864f44a-31e8-4691-a1d3-39c8426ff462" alt="" width="563"><figcaption></figcaption></figure>

Click on ***Choose attributes*** to save or ***Cancel*** to abort.

If you wish to change selected attributes, click on ***Binding attributes*** to the left of ***Add products***. The number next to it shows how many binding attributes are selected.

<figure><img src="https://171427267-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FM9BbYBbDPiJapb75xJ2k%2Fuploads%2FbaFbezOeA091xXtT0Hka%2Fimage.png?alt=media&#x26;token=314fc4da-b7c2-4086-aaef-53634880535c" alt=""><figcaption></figcaption></figure>

The ***Add binding attributes*** window will open again. You can delete a binding attribute by clicking on the ***bin icon*** next to it.

<figure><img src="https://171427267-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FM9BbYBbDPiJapb75xJ2k%2Fuploads%2FosQmoWRNQXnsKafjPFHP%2Fa5e56c0dc2f7.png?alt=media&amp;token=c24a0fb4-0a5f-41cc-ae20-a6bd7d4d8cc7" alt="" width="563"><figcaption></figcaption></figure>

The next step is adding products, so click ***Add products*** on the right side of the bar above the grid (or the same button below ***No product variants***).

<figure><img src="https://171427267-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FM9BbYBbDPiJapb75xJ2k%2Fuploads%2FPCAWXcl2dX6HsoIH21LL%2Fimage.png?alt=media&#x26;token=511de9a5-181d-4e2c-a785-d4f7e22ac0df" alt=""><figcaption></figcaption></figure>

You can ***Select from list*** or ***Generate variants***. Below you will find both options described.

## Select from list

In the newly opened window, you will see a grid of products that have the binding attribute you selected earlier. Tick the products you wish to add and click ***Save changes*** to confirm or close this window to cancel. The number on the button shows how many products are ticked.

<figure><img src="https://171427267-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FM9BbYBbDPiJapb75xJ2k%2Fuploads%2FHmWNYFtADJoHqtXPGW2b%2Fimage.png?alt=media&#x26;token=2d07ef22-8244-4f63-bbee-0ff475c3c808" alt=""><figcaption></figcaption></figure>

{% hint style="info" %}
The products on the list are those that share the same binding attribute on the template assigned to them. This attribute must also have a value assigned for the product to appear on the list.
{% endhint %}

Product(s) will be added as a variant. The number on the ***Variants*** tab shows how many variants the product has, and the grid shows the value of each binding attribute in its own column. If you wish to open this variant (product), click on the ***eye icon***.

To detach it, click on the ***remove (circled cross)*** icon.

<figure><img src="https://171427267-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FM9BbYBbDPiJapb75xJ2k%2Fuploads%2FJqYvDjDljZ0jgM5k7wbm%2Fimage.png?alt=media&#x26;token=2d11bf90-8f9a-480c-9e93-982e0dca0b0d" alt=""><figcaption></figcaption></figure>

## Generating variants

There are some options to configure variant generation beforehand.

<figure><img src="https://171427267-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FM9BbYBbDPiJapb75xJ2k%2Fuploads%2Fxbjn2I7b25uA0kn2Vchd%2F9f1daeaab2d7.png?alt=media&amp;token=8114155b-de50-4de9-8aca-946fa43b5e5e" alt="" width="563"><figcaption></figcaption></figure>

{% hint style="info" %}
Generating SKUs for newly generated variants uses translations in the selected language if available; if not, codes are used as a fallback.
{% endhint %}

| Option name                          | Description                                                                                                                                                                                                                  | Additional information                                                                                                                                                                                                                             |
| ------------------------------------ | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| Binding attribute values             | Specify the values of binding attributes from which product variants will be generated.                                                                                                                                      | This field is required.                                                                                                                                                                                                                            |
| SKU format of the variant            | Specify the SKU format of generated variants, it's based on the binding attribute values. SKU of variants will start with the parent SKU. A sample SKU of the variant is shown below the fields.                             | If there is more than one binding attribute, a user may change their order by dragging and dropping them, however, the parent SKU must always remain first .                                                                                       |
| Generate variant SKUs automatically  | When generating variants, SKUs are always built from a hardcoded pattern (parent SKU + attribute values), bypassing the global Auto-SKU configuration (Settings > Product SKU settings). This setting changes this behavior. | ***Generate SKU automatically*** must be enabled in [Settings](https://usermanual.ergonode.com/system/settings/sku).                                                                                                                               |
| Separator                            | A sign used as a separator in newly created variants' SKUs.                                                                                                                                                                  | This field is required. Options: Dash (-), Underscore (\_), Dot (.), Comma (,), Slash (/), No separator.                                                                                                                                           |
| Language of attribute value          | The language from which values will be taken to create the variant SKU.                                                                                                                                                      | This field is required.                                                                                                                                                                                                                            |
| Use parent product template          | Automatically assign the template used in the parent product to newly created variants.                                                                                                                                      | On by default. If turned off, it's possible to choose a different template from a drop down.                                                                                                                                                       |
| Product template                     | Allows to choose a different template to use with newly generated variants.                                                                                                                                                  | Shown only if *Use parent product template* is set as OFF.                                                                                                                                                                                         |
| Copy parent product categories       | If ON, categories assigned to parent products are automatically assigned to newly generated variants.                                                                                                                        | Default: OFF                                                                                                                                                                                                                                       |
| Category                             | Allows to pick categories to be copied.                                                                                                                                                                                      | Shown only if *Copy parent product categories* is set as ON.                                                                                                                                                                                       |
| Copy parent product attribute values | If ON, values of attributes from parent products are automatically copied to the same attributes in newly generated variants.                                                                                                | Default: OFF. If the user does not have sufficient attribute privileges (edit), (available with higher licenses), he may not see all available attributes. Also for an attribute to be visible, it must have a value in the main "mother" product. |
| Attribute values to be copied        | Allows to choose which attribute values will be copied to newly generated variants.                                                                                                                                          | Shown only if *Copy parent product attribute values* is set as ON.                                                                                                                                                                                 |

Click on ***Generate variants*** to continue. The number on the button shows how many variants will be generated. A confirmation window will appear: click on ***Start batch action*** to confirm or ***Cancel*** to abort.

<figure><img src="https://171427267-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FM9BbYBbDPiJapb75xJ2k%2Fuploads%2FxqFTZrMrvI5gYmuot08U%2F75231bce70f1.png?alt=media&amp;token=e38ca894-38e6-4e5c-ada6-8fa992313083" alt="" width="563"><figcaption></figcaption></figure>

{% hint style="info" %}
The generation of variants is done in the background. When the process is complete, users will be notified via the [Action center](https://usermanual.ergonode.com/dashboard/dashboard/user-menu-and-action-center/action-center).
{% endhint %}

<figure><img src="https://171427267-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FM9BbYBbDPiJapb75xJ2k%2Fuploads%2FaLpDCLTG3NN71DC2IM7e%2Fc5eac39f3d8a.png?alt=media&#x26;token=eb34b46d-2261-4f75-ace2-ecbf6656d1cc" alt="" width="563"><figcaption></figcaption></figure>

## Detach the product

To detach the product from the parent product, tick it in the grid and click on ***Detach variants*** in the bar above the grid.

<figure><img src="https://171427267-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FM9BbYBbDPiJapb75xJ2k%2Fuploads%2FC8kl6epCQwuCbQ9DW5p1%2Fimage.png?alt=media&#x26;token=5b8190b6-029a-488c-aa2b-5247cfe8ff60" alt=""><figcaption></figcaption></figure>

{% hint style="info" %}
Detached products are NOT deleted; they become single simple products. If you wish to delete the generated variant, you must first detach it and then delete it from the [Product Catalog](https://usermanual.ergonode.com/products/catalog) location.
{% endhint %}

Click on ***Start batch action*** to confirm or ***Cancel*** to abort.

<figure><img src="https://171427267-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FM9BbYBbDPiJapb75xJ2k%2Fuploads%2FFopid7OqKk91XbYMZxG0%2F26658bc61dc2.png?alt=media&amp;token=57b1bac2-6519-4dbc-a85e-661b2ec6c152" alt="" width="563"><figcaption></figcaption></figure>

{% hint style="info" %}
Detaching variants is done in the background. When the process is complete, users will be notified via the [Action center](https://usermanual.ergonode.com/dashboard/dashboard/user-menu-and-action-center/action-center).
{% endhint %}

<figure><img src="https://171427267-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FM9BbYBbDPiJapb75xJ2k%2Fuploads%2Ff1FWjn9KlgEtzC4PTLue%2Fd62ccbff5c54.png?alt=media&#x26;token=840f3ae9-44ee-4b9f-aac8-f3d9393189fd" alt="" width="563"><figcaption></figcaption></figure>


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://usermanual.ergonode.com/products/catalog/creating-new-product/product-with-variants.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
