> For the complete documentation index, see [llms.txt](https://documentation.siteglide.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://documentation.siteglide.com/ecommerce/get-started-ecommerce/cart-checkout-and-quotes/managing-products/discounts.md).

# Discounts

Add Discount Codes to your eCommerce Module to incentivise customers.

Discount codes can be created with a code which can be shared with selected users. They can be modified with:

* A percentage or flat value to reduce the price of the Cart, or Basic Payment Form submission.
* A restriction of which products or product categories they apply to
* A limit to the number of uses they can have
* Expiry dates
* And more

## Creating a Discount Code

<figure><img src="https://584571746-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Ft7n2OYNNUr9PgpkBD2eX%2Fuploads%2Fgit-blob-0b87ea9a4b0f5a5d2ae9c0eed7b8359a9290da38%2FCapture1.PNG?alt=media" alt=""><figcaption></figcaption></figure>

<figure><img src="https://584571746-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Ft7n2OYNNUr9PgpkBD2eX%2Fuploads%2Fgit-blob-45a0f595d11761c8e1ae5824e56ad018cecbbad8%2FCapture2.PNG?alt=media" alt=""><figcaption></figcaption></figure>

## Restricting a Discount Code to Specific Products or Categories

Sometimes you will want to give different discounts to different products or catalogues of products. This can work in Siteglide without any additional code.

By default, every discount code applies to all eCommerce Checkout products. But if any products or categories are specified, the discount code will only apply to specified products and categories.

At that point:

* The customer will need to spend enough on eligible products to meet the discount code's minimum spend.
* The customer will only recieve a discount on the eligible products. They can still buy other products at the same time, but they will remain full-price.

In the "Standard Fields" tab, you can use the dropdown field labelled "Products this Discount can be applied to" to select eCommerce checkout products individually which the code should apply to.

<figure><img src="https://584571746-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Ft7n2OYNNUr9PgpkBD2eX%2Fuploads%2Fgit-blob-8f04a7460e27c979005aba399ed4196db9bc0db6%2FCapture3.PNG?alt=media" alt=""><figcaption></figcaption></figure>

In the "Categories" tab, you can select single or multiple categories to make all products which share the category (see [Product Categories](https://documentation.siteglide.com/ecommerce/get-started-ecommerce/cart-checkout-and-quotes/managing-products/product-categories.md)) eligible for the discount.

![](https://584571746-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Ft7n2OYNNUr9PgpkBD2eX%2Fuploads%2Fgit-blob-393330be9e830af08526ba38b3ba3251d6d0f3fd%2Fimage.png?alt=media)
