I need help on how to create a Shopify function discount that will give a certain percentage and capped at a fix cost. Example I want to give 10 % discount to be capped at $50. So if the discount is $100 the discount value will be $50 because $100 is greater than $50 but if it less than $50 then the discount value can be is ok
1 Like
@Dammie , you should be able to do it by checking what the actual amount would turn out to be when the percentage is applied. If it’s more than the maximum amount allowed, set the discount to be that amount instead of percentage.
We allow this exact same thing in our app, Discount Bot. Here’s a screenshot of the setting - you should be able to implement something similar in your app:
The cart applies only a $3 discount instead of 50% ($5) discount.
Hi @Dammie ![]()
This is Ellie from BOGOS.
You can use ADU: Automatic Discounts to create what you want. Please see my attached screenshot, you can easily set a maximum limit for your discount.
If my answer is helpful, I would appreciate it if you could give me a Like or accept it as a Solution!
Ellie


