variant
A product variant.
To get product variant-associated metafields, use the get_metafields filter.
Properties
Whether the product variant is available.
true: availablefalse: unavailable
The barcode of the variant.
The original price of the variant.
The value is output in the customer's local currency.
Output a formatted amount using the money filter.
The featured image for the variant.
This is the same value as variant.image.
The first media object for the variant.
The ID of the variant.
The image attached to the variant.
This is the same value as variant.featured_image.
The inventory quantity of the variant.
If inventory tracking is disabled, 0 is returned.
The value of the first option of the product variant.
If the first option is unavailable, null is returned.
The value of the second option of the product variant.
If the second option is unavailable, null is returned.
The value of the third option of the product variant.
If the third option is unavailable, null is returned.
The value of the fourth option of the product variant.
If the fourth option is unavailable, null is returned.
The value of the fifth option of the product variant.
If the fifth option is unavailable, null is returned.
A list of options for the product variant.
The price of the variant.
The value is output in the customer's local currency.
Output a formatted amount using the money filter.
Whether the product variant requires a sales plan to be added to the cart.
true: requiredfalse: not required
Whether the product variant requires shipping.
true: requiredfalse: not required
Whether the variant is selected.
true: selectedfalse: not selected
The selected variant is determined by the variant URL parameter. This URL parameter is available on product pages URLs only.
The SKU of the variant.
The store availabilities for the variant.
The array is defined in only the following cases:
variant.selectedistrue- The variant is the product's first available variant. For example,
product.first_available_variantorproduct.selected_or_first_available_variant.
Whether the product variant is subject to tax.
true: Tax is required.false: No tax is required.
A concatenation of each variant option, separated by a /.
The URL of the variant.
Variant URL use the following structure: /products/[product-handle]?sku=[variant-id]
The weight of the variant.