In this article, you will learn how to create rules for coupon codes on your eCommerce Magento 2 store. Please follow the step-by-step instructions below.
Step 1. In the Magento 2 admin panel, go to Marketing > Promotions > Cart Price Rules

Step 2. Click “Add New Rule”

Step 3. Provide the rule information
Detailed description:
- Specify the Rule Name for your price rule.
- Activate the rule by setting Status option to Active.
- Select the website(s) where the rule will be applied.
- Select the specific customer group(s) your coupon will be available for.
- Select the Coupon for the rule (if any). All the other fields in the Rule Information section are not mandatory to fill in, you can use them according to your requirements.

Step 4. Set up rule conditions
Detailed description:
- Setup the condition(s) for the rule (Leave blank for all products).

Step 5. Configure pricing structure rules
Detailed description:
- Select the discount type this rule will be applied to.
- Specify the Discount Amount. All the other fields in the Actions tab are not mandatory to fill in, you can use them according to your requirements.
- Set up the conditions for the rule which will be applied only to cart items (Leave blank for all items).

Step 6. Specify the Default and Store View Specific labels
Detailed description:
- Specify the Default Rule Label for All Store Views.
- Indicate Store View Specific Labels for your website(s).
- After you completed creating cart price rule in your Magento 2 admin panel – press the Save button to save your changes.

Important Information:
After all the changes have been done and saved, please refresh and flush Magento 2 Cache.