DBDTV Tutorial: How to Add a Discount Code to an Individual Product in Magento
Hello everybody this is Angela for DBDTV and today we’re going to take a look at how to add a discount code to an individual product within Magento eCommerce system.
Unlike adding a discount that applies to the whole shop, adding a discount to an individual product can be a little tricky.
So lets get started quickly.
Magento eCommerce Dummy Shop
This is the front end of a dummy Magento shop. Currently we are in the All Products category. As you can see this is a pretty small shop with only 9 items.
So lets say we wanted to add a 25% discount to just one product, let’s use the Back Pack for our example.
Enable SKU Attribute for use with Promotion Conditions
The very first thing we need to do if we go to Magento’s back end is to navigate to Catalog > Manage Attributes.
Attributes are product properties or features such as colour, size or weight etc. What we are interested in here is an attribute called SKU.
SKU stands for Stock Keeping Unit and is a system of identification used for inventory purposes. Different companies have their own systems of alpha-numeric codes to identify and track their lines and products.
No two products can have the same SKU and Magento itself does not allow this, so you won’t be able to accidentally duplicate a SKU code within the system itself.
With that in mind, we will be using the SKU to identify the product to which we would like to add the discount code to.
But to do so we need to enable SKUs to be used for Promotion Conditions.
Select or search for SKU attribute by tabbing through the pages of attributes (your site may have more or less product attributes depending on how your shop has been set up and the kinds of products you are selling.
As there are quite a lot of attributes here I’ll perform a quick search.There it is, just click on SKU to edit it’s properties.
We need to enable SKU to be used for Promo Rule Conditions, so scroll down and select Yes from the dropbox. Finally just click Save Attribute.
Check the Product’s SKU code
Next we need to check the SKU of the product that we wish to apply the discount code to.
Navigate back to Catalogue > Manage Products.
Select the relevant product, in this case our Back Pack.
The SKU is in the first General tab within the product. Here we can see that the SKU for this product is BP00009, make a note of this. If your product does not have a SKU then you must add one, even if you do not have an SKU system in place.
Shopping Cart Rules
Finally we need to create the discount code.
Go to Promotions > Shopping Cart Rules and hit Add New Rule.
Give the rule a name, it doesn’t matter what this is but it is useful to make it meaningful so that if you have a number of discount codes running on your eCommerce site, you know which is which at a later date.
Ensure status is ‘Active’.
Select the site that you want to use this discount on. A single instance of Magento can run multiple sites. Here we only have one and it’s called test.
Next we want to select the users that we will allow to use this code. In this case we don’t want to offer Wholesales or Retailers who have their own log in accounts to be able to use the code as they have their own discounted rates for buying in bulk.
Instead we want to offer our customers this discount, so we select both General, which applies to customers that are logged in via their own accounts, and Not Logged In which will normally be new customers to the site.
We then want to select Specific Coupon, from the Coupon Dropdown Menu, and add in our discount code. This will be the code that people need to enter when they purchase the product.
I’m just going to use the name we used for the rule which is DISBAG25
Fill in the Uses Per Customer field. In my case I just want each customer to be able to use the code once.
Next we need to add a date range in which the discount code may be used. I’m going to set this as today and tomorrow only.
Now switch straight to the Actions tab in the sidebar.
Here we want to discount our backpack by 25% of it’s original price.
Also we only want our customers to be able to apply this discount to 1 backpack.
Finally we want to set a condition, whereby if the customer has the Yellow Backpack in their cart, the condition is considered true, and the discount will be applied.
To do this we click the green ‘plus’ icon, select SKU from under the Product Attribute heading in the dropdown, and add in the products SKU number, which is BP00009.
Finally don’t forget to send out your discount code via social media, newsletter, or whatever channel you prefer to use to promote your site.
Back on the Front End
Back on the front end, a customer with the relevant discount code can then:
> add the product to their cart
> View their cart
> Add the discount code, in this case DISBAG25
And as we can see 25% has been discounted off the product price of the Yellow Back back rather than cart total meaning they can then checkout and pay £61.25 instead of £75.00.0
So that’s it! If you have any questions, just comment below and I’ll do my best to answer them as soon as I can.
In the meantime do visit our blog for other digital hints and tips at designbyday.co.uk/blog
Thanks for watching DBDTV.