I'm trying to create a coupon code that will apply a discount to an item in a cart if it is in a certain category but won't discount other items that are also in the cart.

I tested out what I created and the discount didn't apply when I had an item in the cart that wasn't in one of the categories but when I added an item that was in a category it applied the discount to everything in the cart.

This is what I have set up so far: Conditions

enter image description here


1 Answer 1


Can you please use "contains" or "is one of" and see if that works.

enter image description here

  • I changed it to both and tested and it is still doing the same thing, it is taking the discount off the subtotal and I am wanting the discount only to be applied to the items that are in the categories I've chosen.
    – Ana S
    Commented Sep 1, 2020 at 19:38
  • 1
    @AnaS did you manage to get any workaround or Magento 2 patches for this ?
    – sodhancha
    Commented Jan 27, 2021 at 5:32

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.