Creating Product-Specific Coupons in Magento
In this post, we’ll guide you through creating a coupon in Magento that applies exclusively to a specific product. Let’s assume you have a 10% off coupon code and you want it to be applicable only to Product B.
Understanding the Cart Scenario
Let’s visualize the cart situation:
- You have three products: P1, P2, and our target product, B.
- The customer adds these items to their cart:
Product P1
Product B (The one we want to apply the coupon to)
Product P2
The Challenge: Applying Coupons to Specific Products
By default, Magento applies coupons to all products in the cart. However, you want this 10% off coupon to work only for Product B. Here’s how to achieve that:
Step 1: Create a New Cart Price Rule
Navigate to Marketing -> Promotions -> Shop Price Rules and click on Add New Rule.
In the Rule Information section, fill in the necessary details like rule name, customer groups (if any), and status.
Step 2: Define the Conditions for Your Coupon
Switch to the Conditions tab. Here’s where we’ll restrict this coupon to Product B:
-
If All of These Conditions Match:
- Add the first condition as
Product SKU is one of. - In the text box below, enter the SKU number or name for Product B.
- Add the first condition as
-
If Any of These Conditions Match (leave it blank)
-
If ALL OF THESE CONDITIONS APPLY TO:
- Add a new condition as
Cart Item Attribute. - Set the attribute to
skuand chooseis equal to. - Enter the SKU or name for Product B.
- Add a new condition as
Step 3: Define the Discount Actions
Switch back to the Actions tab:
- Apply: Choose
By % of total - Discount Amount: Enter your desired discount, e.g., 10
- Maximum Qty Discount is Applied To: Leave it as
No Limit
Step 4: Test and Apply Your Rule
Before saving:
- Click on
Testto ensure the rule applies only to Product B when added to a cart. - If satisfied, click
Save Rule.
Now, whenever a customer adds Product B to their cart and enters your coupon code, they will receive a 10% discount on that item alone.
Conclusion
Creating product-specific coupons in Magento requires careful setting up of conditions within the Cart Price Rule. By following this guide, you can now offer tailored discounts for specific products, enhancing both the customer experience and your store’s revenue management.
For more advanced coupon strategies and Magento best practices, check out our guide on Magento 2 Advanced Promotions.