How to Create Coupon Code In Magento Store?

magento website hosting

Table of Content

  1. Introduction
  2. How to create coupon codes in Magento Store?
    1. Create a specific Coupon
    2. Create multiple Coupons 
  3. How to Configure Coupon Codes?
  4. Conclusion


The most effective and straightforward strategy to enhance your Magento eCommerce store’s business is to use a coupon code. This code also assists you in setting up promotions on your sites, such as providing consumers with free delivery for a limited time in exchange for their loyalty and providing them with discount offers depending on your terms and conditions.

The majority of promotions, discounts, and special deals include coupon codes. I’ll show you how to create Magento discount codes in the most straightforward method possible, so your consumers can get the most out of these offers!

How to create coupon codes in Magento Store?

You must first build a new cart price rule to create a Magento 2 coupon code, which will be used to compute the discount with the Magento 2 coupon code you create. Navigate to Marketing > Promotions > Cart Price Rules, click Add New Rule, and click the Rule Information tab. Choose a Specific Coupon from the Coupon dropdown and enter your Magento 2 coupon code or use auto-generation.

Let’s go deep and create single and multiple coupons following the steps.

Create a specific Coupon

  • On your Magento dashboard, go to Marketing > Promotions > Cart Price Rule > Add New Rule to create a new rule. Give the rule a name, describe it, and turn on the Rule. Then, choose the website where the promo code will be valid and define the customer groups for which a coupon is intended.
  • Choose a specific coupon and create a coupon code for it.
  • Define the number of times the discount code can be used in the Uses per Coupon field. If the coupon code has no restriction, leave this field blank.
  • Define the number of times a single registered user can use this promotional code by selecting Uses per Customer. If there is no limit, leave it blank.

Note that this option does not apply to guests (NOT LOGGED IN group) or customers who haven’t signed in to make a purchase.

  • Choose the From and To Dates to set the duration of the Magento promo code’s validity.
  • If many rules meet the conditions, set the Priority so that only the rule (coupon code) with the highest priority is used.
  • Decide whether or not to make the RSS feed public.
  • Set the Conditions for customers to apply the promo code based on the status of their shopping cart. As a result, they are solely based on Cart Attributes.

Don’t forget to save the promo code and check it on the storefront once you’ve finished. Simply add things to your cart to meet the rule’s requirements and apply the coupon.

Create multiple Coupons 

You must also add restrictions, discount amounts, and other settings when automatically generating coupon codes in Magento. The only difference is that you need to select Use Auto-Generation, which means you won’t be able to enter your coupon code; it will generate automatically.

  • Go to the Manage Coupon Codes option inside the rule section.
  • Enter the Coupon Qty, which tells you how many coupon codes you want to create.
  • Change the Code Length setting to define the number of characters in a discount code.
  • Choose a code format.
  • To be included in the code, provide the Code Suffix and Prefix. It can be used to distinguish auto-generated coupon codes from other coupons.
  • Press the Generate button after stating the Dash Every X Character.

Note that the code length contains dashes, suffixes, and prefixes.

Coupons are generated by cron and queued, so they can take a long time to generate, especially if you want to create a significant number of coupons at once. While you’re waiting, don’t forget to Save the rule.

The discount codes will appear in the grid once they have been produced.

How to Configure Coupon Codes?

Let’s look at how to set up coupon codes. The parameters control the length and format of auto-generated coupons. You can use the dash to make the code simpler to understand, and you can choose Numeric, Alphabetical, or Alphanumeric format.

  • First, go to Stores >> Settings >> Configuration.
  • Select the Promotions option inside of the Customers tab.
  • Expand the section for Auto-Generated Specific Coupon Codes.
  • In the Code Length area, enter the number of code symbols.
  • From the Code Format selection, select the required format.
  • Enter the required value in the corresponding areas if you wish to add a prefix or suffix to your code.
  • In the Dash, Every X Characters area, enter the number of characters between each dash to add separators to your code.
  • Do not forget to save the changes.


You can create coupon codes by following this guide. All steps are mentioned to help you do your job. If you want the steps to be done quickly without doing anything, you can add an extension. You can contact the support of your Magento website hosting company in case of any problem in the installation process; you can create coupon codes effortlessly with the Easy Coupon Manager Extension.