All Collections
Data Sources
Basics
Data Sources And The Cart
Data Sources And The Cart

This article will go over how you can dynamically display recommendations based on cart-based rules such as Cart Subtotal and count.

Strauss Van Wagenen avatar
Written by Strauss Van Wagenen
Updated over a week ago

These rules will only work for cart-based widgets. From the widget selections of the Rebuy Online Store this would be "Cart", "Shopify Checkout", "Recharge Checkout", "Shopify Thank You", "Recharge Thank You", "Post Purchase" and "Global" widgets. A "Product Page" widget does not have access to the cart object. The product page widget only has access to the product page that is currently being viewed.

  • Cart Item Count

  • Cart Line Count

  • Cart Subtotal

Cart Item Count

This is referring to the exact amount of items that are in the cart including items that are the same. So if the customer has 2 of the same item and 1 of another item then that would evaluate to 3 total according to this rule. This is the total of all the items regardless of having duplicates of any items.

Cart Line Count

This is referring to the number of different items in the cart. So let's say the customer has 2 of the same item then that evaluates to 1 according to this rule. Because they are buying 2 of the same thing here.

Cart Subtotal:

This is typically paired with a free gift with purchase type of widget but the same idea applies if you would like to use the cart subtotal rules for other display type widgets.

With this rule, we have three options. (In greater than, Is less than, Is equal to)

  • Is greater than refers to if the cart subtotal is greater than $XX.XX

  • Is less than refers to if the cart subtotal is less than $XX.XX

  • Is equal to refers to if the cart subtotal is exactly equal to $XX.XX

Example of "Is Greater Than"

This rule will return the specific product if the cart subtotal is greater than $50.00. This is commonly used with a Gift With Purchase where the customer has to spend a certain amount in order to receive the free gift.

Example of "Is Less Than"

This rule will display relevant products that are less than $10.00 where the return statement has "Product price is less than or equal to $10.00." This could be helpful at checkout where you do not want to display products that are expensive and require more investigation to feel comfortable to add on.

Example of combining "Is Greater Than" & "Is Less Than"

This rule will only match if the cart subtotal is greater than $35.00 and the cart subtotal is less than $50.00. This can be helpful if you have a free shipping threshold and you are pushing the customer to spend enough to get free shipping. This rule is commonly paired with a Smart Cart Cart Flyout widget especially when the free shipping bar is activated.

Let us know if you have any questions about cart-based rules!

Did this answer your question?