I'm trying to create a shopping cart price run whereby if you buy one of a product in one category, you get one of a product in another category at 50%. I'm trying to also maintain a 1 to 1 ratio on the discount, eg:

If I buy 1 from category A I get 1 from category B at 50%

If I have 1 item from category A and 2 items from category B, only one item from category B gets the 50% discount, the other is at full price.

If I have 2 items from category A, 2 items from category B get 50% off additional items from category B are at full price.

I've set the following on the Actions tab:

Discount Amount 50

Maximum Qty Discount is Applied To 1

Discount Qty Step (Buy X) 1

Stop Further Rules Processing No

If any of these conditions are true, category is category B

As it runs now, if I put one item from category A all of category B get the 50% discount. I'm stumped on this one...

  • Could you please provide some of your code you already wrote?
    – Tobias
    Commented Mar 28, 2013 at 8:12
  • Not using any code, trying to do this from the admin area
    – Roscius
    Commented Mar 29, 2013 at 21:32

3 Answers 3


It is not possible by default in Magento as far as i know but it can be easily done if you observe this event salesrule_validator_process

  • Was looking to avoid code, but if I must...
    – Roscius
    Commented Mar 29, 2013 at 21:33
  • There is another answer from here: magento.stackexchange.com/questions/16053/….
    – Ner
    Commented Nov 20, 2017 at 13:02
  • 1
    This is not possible with Magento 1. I suggest you use a third party module like the Special Promotions Pro from Amasty (goo.gl/9WxbA4)
    – Ner
    Commented Apr 30, 2018 at 7:31
  • any one have code for same ? Commented Oct 24, 2018 at 11:19

This is possible.

In the admin panel, click on Promotions -> Shopping Cart Price Rules (because we are dealing with products in the cart)

In the Conditions tab,click the little plus symbol and select 'Product Attribute Combination'.

Select the new plus symbol and select category. Click on the '...' and select the category for the products you want to have in the basket for you to get the discount.

Now click on the Actions tab, in 'Apply' have 'Percent of product price discount'. In Discount Amount, enter 50 (for 50%). In the conditions at the bottom, click on the plus symbol and select Category. Click on the '...' to select the category for the products you want to apply the 50% discount to.

This will get you 50% off all products in cat b when you have >= 1 products from cat a in the cart.

There are further conditions that can be specified (minimum number of products from cat a, maximum number of products to apply discount to). It will require a lot of experimentation to get the conditions correct for your specific needs, but hopefully I have pointed you in the right direction.

  • Nice Solution! ;-)
    – user505988
    Commented Jan 11, 2015 at 23:21
  • @richard : Your suggested one working good, but let me know is it possible in the same category of products, if the product in the cart, other products of the same category applied 10% discount, no discount for a just single product of the category have 10% discount. If other products in the same category then only apply the discount?
    – zus
    Commented Oct 3, 2017 at 10:35

Under Conditions tab, select total quantity to be greater than 2 for that product. Now under Actions tab

  1. Apply: Percent of product price discount
  2. Discount Amount: 25%
  3. Discount Qty Step (Buy X): 2

And in apply rule section select your sku

  • Thanks, this was really useful :)
    – PauGNU
    Commented Jun 29, 2020 at 9:55

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.