Build rules
Conditions: when a rule applies
Every ShipRule condition and comparison, how to combine conditions with AND, OR and condition groups, and how each condition is matched at checkout.
Conditions decide when a rule’s actions run. They live in the Conditions card of the rule editor. With no conditions, the rule applies to every checkout.
Add a condition
- In Conditions, click Add condition.
- Choose what to check. Conditions are grouped under Cart, Location, Products and Customer.
- Choose a comparison, such as is at least or is any of.
- Enter the value.
A short hint under each condition explains what it checks. To remove a condition, click ×. Conditions that aren’t on your plan show the plan that includes them, such as — Growth, and can’t be selected.
All conditions
| Condition | Comparisons | Plan |
|---|---|---|
| Cart subtotal | is greater than, is at least, is less than, is at most, is equal to, is not equal to, is between, is not between | All plans |
| Cart total | Same as cart subtotal | All plans |
| Total item quantity | Same as cart subtotal | All plans |
| Shipping country | is any of, is none of | All plans |
| Shipping state / province | is any of, is none of | Growth and up |
| Shipping postal code | is any of, is none of, starts with any of, starts with none of, is between, is not between | Growth and up |
| Products in cart | includes any of, includes none of, only contains | Growth and up |
| Product tags | includes any of, includes none of, only contains | Growth and up |
| Product collections | includes any of, includes none of, only contains | Growth and up |
| Customer tags | includes any of, includes none of | Growth and up |
| Customer is logged in | is (Yes or No) | Growth and up |
Location conditions are covered in Location rules, and customer conditions in Customer rules.
Cart conditions
- Cart subtotal is the item total before shipping and taxes. Cart total is the total Shopify reports to shipping rules.
- Enter amounts in your store’s currency. For buyers paying in another currency, ShipRule converts your amount automatically.
- Total item quantity counts every unit: two of one product and one of another is 3.
- is between includes both ends: between 50 and 100 matches 50 and 100.
Product conditions
- Products in cart and Product collections use Shopify’s picker: click Choose products or Choose collections.
- Product tags takes typed tags: type one and press Enter.
The comparisons look at every item in the cart:
- includes any of — at least one cart item matches.
- includes none of — no cart item matches.
- only contains — every cart item matches (and the cart isn’t empty).
So Product tags only contains preorder means the whole cart is pre-order products.
Combine conditions
Each group of conditions has a Match setting:
- all conditions (AND) — every condition must match.
- any condition (OR) — at least one must match.
Condition groups
On the Pro plan, click Add condition group to mix AND and OR, for example (A and B) or C. With more than one group, choose Apply when all groups match or any group matches. A rule can have up to 10 groups, with up to 20 conditions in each.
Example: Group 1 matches all: Shipping country is any of US and Cart subtotal is less than 75. Group 2: Customer tags includes any of wholesale. With any group matches, the rule applies to small US orders and to every wholesale order.
Lists of values
Countries, states, postal codes and tags take several values. Type one and press Enter or a comma, or paste a list separated by commas or new lines. A condition can hold up to 500 values. Several values mean “any of them”.
How conditions are matched
- Missing information never matches “any of” comparisons. If an address has no postal code, postal code is any of … is false, while is none of … is true.
- Guests have no customer tags, so Customer tags includes none of … matches every guest.
- Location is checked per delivery group, using that group’s shipping address.
Check your rule
After saving, test the rule in your store’s checkout with a cart that should match and one that shouldn’t. See Create your first rule.