Can I make a "buy x/get y" discount go over multiple orders?

Can I make a "buy x/get y" discount go over multiple orders?

TheBeastiary
Tourist
5 0 1

Hello,

 

At my store we have a buy 12 get the 13th bag free for most of our dog food.

This can be done over multiple orders and the company refunds us but it is a massive pain going through all the orders and adding them up.

Is there a way I can automate this and also have it show up on the receipt for the customer to see?

 

The buy x get y seems to only work on single orders.

 

Thanks!

 

-Josh

Replies 3 (3)

tobebuilds
Shopify Partner
447 32 120

Hi Josh,

I can totally see how frustrating it would be to manually do this.

I recommend you use a customer metafield to track the total number of bags a customer has bought in their lifetime.

 

The tricky part will be finding a way to automatically update the metafield value when an order is paid. You have 2 options:

  • Use Shopify Flow (free app from Shopify). However, I'm not sure whether Flow can do complex calculations. I've found two past threads (thread 1 and thread 2) that outline different approaches to counting the number of specific items in a cart.
  • Or, create a custom app. Register a webhook that triggers after an order is paid.  Add the quantity of bags from the order to that number, and update the metafield value. This is most straightforward, but requires technical knowledge.

Once the metafield is set up, you can create a discount that applies a discount to 1 bag of dog food, only if the customer's metafield is "12." Or, if it's "25," apply a discount to 2 bags, and so forth.

 

If you're on Shopify Plus, you can build a custom app with the Shopify Functions API to create an automatic discount that implements this logic.

 

If you're not on Plus, or don't want to build a custom app, then you can also set this up with our app, Regios Automatic Discounts (4.9 stars, Built for Shopify).

 

Here's a screenshot of how you could set this up in our app:

 

tobebuilds_1-1724818953502.png

 

 

  1. Add a "Check if" step.
  2. Add an "Include/exclude customers" condition.
  3. Select "Customers with a specific metafield."
  4. Select the metafield definition, and then enter "12"
  5. Add an "Include/exclude products" condition.
  6. Select "Specific collections" and select your "Dog Food" collection.
  7. Press "Then," then add an "Apply discount" step. Set it 100% off, with a quantity of 1.
  8. Press "Otherwise," then add a similar setup, but for a metafield value of "25"
  9. Repeat for all your tiers.

 

One downside of this approach, as opposed to a custom app, is that we currently don't support infinitely applying the discount based on the customer's metafield value. You would have to create a finite set of tiers, such as 12, 25, 38, etc.

 

If you have any questions about this, just reply, and I'll be happy to help.

 

Best,

Tobe

Founder, Regios Discounts app (4.9 stars, 54 reviews)
- Custom discounts made simple
- "Just about any discount you'll ever need"
- Built by an ex-Google software engineer

Ellie-BOGOS
Trailblazer
147 17 24

Hi @TheBeastiary 😁

 

This is Ellie from BOGOS (formerly Free Gifts by Secomapp), #1 Promotion App on Shopify featuring Free Gift, Discounts & Bundles.

 

To automate the adding 13th free bag to your customer cart, consider using our BOGOS app. The system will automatically add the free bag to the customer’s cart. 

 

→ Simply set the “Cart quantity condition” to 12 in the “Min” field. This means customers must purchase at least 12 bags to receive the 13th one for free. You can apply this condition to many methods:

Screenshot 2024-08-29 120153.png

 

--> Then select the bag you want to offer for free in the "Select gift" section:

Screenshot 2024-08-29 120306.png

 

 

Grab 7-day free trial of BOGOS (4.9 overall rating & 2,010+ reviews) to give it a try!

 

If my answer is helpful, I would appreciate it if you could give me a Like or accept it as a Solution!

 

Wish you all the best with the business,
Ellie
BOGOS (formally Free Gifts by Secomapp)

If it is helpful, let me know by giving a Like or Accept solution.
Use BOGOS.io Free gift to create special promotions: BOGO, gift with purchase, product bundles, quantity breaks on your store!
Have a nice day ^_^

JoesIdeas
Shopify Partner
2410 222 644

If you're tracking over time, you could tag the customer for each order, then it would be easily searchable too in Orders or Customers.

 

Example:

1. Customer makes purchase and has 1 bag of dog food in the order, tag order DF1.

2. A week later they buy 2 bags of dog food, remove tag DF1 and tag order DF3

3. On the 12th or 13th order, would depend how you handle your system, could either add a free product to the order, or have a notification to staff to check the order to apply the refund or freebie, however you do it.

 

If the apps you have now don't automate that, people user Order Automator to do stuff like that. I've seen this exact use case before, that's where the idea came from.

• Creator of Order Automator [auto tag, fulfill, connect FBA, order jobs]
• Co-Creator of Product Automator [suite of features for products / collections]
• Shopify developer for 10+ years, store owner for 7 years
• Blog: Shopify Tips, Guides, and Automation Tools