Use Price Rules quantity-pricing conditions to offer volume discounts to customers who purchase products in multiple units or large numbers.
Price Rules supports these quantity-pricing condition types:
|Condition type||Description||Example use case|
|Offer discounts based on the quantity of a product variant in the cart.||Buy 3 packages of t-shirts (gray color only) to get a $10.00 discount.|
|Offer discounts based on the number of products in the cart.||Buy 12 cans of pet food (any variety) to get a $10.00 discount.|
|Offer discounts based on the total number of items in the cart.||Buy 10 items to get a $10.00 discount.|
|Offer discounts on Y items when the cart total is equal to or above X.||A promotion of “Spend $100, get a free bag”.|
Using quantity-pricing conditions
Quantity-pricing conditions typically require these properties:
|string enumeration||The type of quantity-based condition.|
|integer||The quantity of products, product variants, or items that must be present to satisfy the condition.|
|string||A comparison operator to use when evaluating the condition. Supported operators include |
The following JSON example uses the
QTY_BY_LINE type to create a condition that is satisfied when five or more items are present in the cart:
Creating volume discounts
Combine quantity-pricing conditions with price adjustments to create volume discounts.
To create a volume discount rule, follow this pattern:
- Add a new rule to your ruleset and set the rule
typeto one of the discount layers —
STACKABLE_DISCOUNT. (For more on working with rule types, see Priority and stacking.)
- Add a quantity pricing condition that defines the volume of products a customer must purchase to qualify for the discount.
- Add a price adjustment action that defines the discount for qualified purchases.
The following example ruleset offers a promotion to customers who respond to an email campaign — buy at least 5 products and get a total discount of 10%:
To publish your quantity-pricing promotion, use the Price Rules API to create a ruleset.
For more examples, refer to the other how-to guides in the left-hand menu.
SPEND_X_GET_Y condition allows you to offer free or discounted items if the cart total is greater or equal to a certain price.
Keep the following considerations in mind when using this condition:
- The price of the item that will be discounted is not considered when determining the price of the cart. For an example of how to use the SPEND_X_GET_Y condition, see quantity-pricing.
- The rule type for this condition must be
- The following actions are supported:
- For product selection, always select a product. Never use
- Do not create multiple rules using this condition that select the same product.
- If creating multiple rules using
SPEND_X_GET_Y, please note that all valid rules will be applied, not just the one that gives the best price. It is possible for multiple
SPEND_X_GET_Yrules to trigger in the same cart.
The following example is a ruleset using
SPEND_X_GET_Y, that sets the value of the
111 product to $0 if the cart price is $100 or more.
"internal_name": "Internal Name",
Consider if the product
111 had a regular price of $20. If you added 5 of the product to your cart, this condition would not trigger, because the price of the cart - excluding the 1 product to be discounted - is $80 (4 * $20). Even though overall the cart price is $100, the item that will be discounted is not considered when determining the price of the cart for the
If you had 6 of the product
111 in your cart, then the price of the cart would be $120, and the price of the cart – excluding the item to be discounted – would be $100. Since $100 is over the value specified in the
SPEND_X_GET_Y condition, the condition triggers and 1 of the 6 items is be discounted to $0. This results in a line price of $100, with each item individually costing $16.67 (since 6 * 16.67 = 100).