1. Home
  2. Knowledge Base
  3. WooCommerce Dynamic Pricing and Discount Rules
  4. Getting Started with Dynamic Pricing and Discount Rules
  5. How to create a discount pricing rule
  1. Home
  2. Knowledge Base
  3. WooCommerce Dynamic Pricing and Discount Rules
  4. Dynamic Pricing
  5. How to create a discount pricing rule
  1. Home
  2. Knowledge Base
  3. WooCommerce Dynamic Pricing and Discount Rules
  4. How to create a discount pricing rule

How to create a discount pricing rule

To create a pricing rule, go to WooCommerce > Settings > Fees and Discounts and ensure that the ‘Enable Dynamic Pricing’ checkbox is selected.

Pricing rules settings

After you’ve saved your settings, go to WooCommerce > Fees and Discounts to add your rules.

Click ‘Add New’ to add a pricing rule.

WooCommerce dynamic rule settings

Offer type

The ‘Rule’’ setting determines the type of pricing rule you’ll create. Choose from:

  • Simple – apply a simple percentage or fixed discount (or fee) to some or all products.
    Example: 10% off all products
  • Buy X Get X – use this setting if you want to create offers like buy one get one free and the product purchased is the same as the product discounted.
    Example: Buy two apples, get one apple free
    There’s a tutorial on BOGOF here
  • Buy X Get Y – this is a broader setting than Buy X Get X, also allowing you to create a buy one get one free type offer, but where the product purchased can be different from the product discounted
    Example: Buy two apples, get a banana half price
  • Bulk Pricing – this allows you to create tiers where the price changes according to the quantity of product selected. This can either be as an adjustment to the base product price, or you can set a different product price per tier
    Example: Get 10% off when you buy 5 or more items
    There’s a tutorial on bulk discounts here
  • Order Total – this allows you to create tiers where the overall cart total changes based on its current value.
    Example: Buy $200 and get a 10% discount
    There’s a tutorial on discounts by order total here
  • Discount on Spend – this allows you to offer discounts based on the amount of spend on a specific item, specific categories or on all items.
    Example: Get $100 off, after spending $1000 on specific items

Label

You can add some optional text to the price label to advertise your offer – e.g. ‘Buy one get one half price’.

Schedule

Status

It’s possible to set a status for the rule – either Active, Paused or Scheduled

  • Active – to activate the rule on the front end
  • Paused – to stop the rule on the front end (but keep your settings, ready to be re-activated at a later date)
  • Scheduled – to start and stop the rule at times you specify.

Applies To Settings

Applies to

Applies to

Use this setting to determine which products the offer will apply to. Choose from:

  • All items – all items in the store will be eligible for the offer
  • Specific categories – this will open a new field where you can select which categories are eligible for the offer
  • Specific products – this will open a new field where you can select which products are eligible for the offer

Count by

The ‘Count by’ setting defines how to count items to trigger the offer. Choose from:

  • All – if you select ‘All’ here, then all items in the cart will be totalled
  • Product – if you select ‘Product’, the plugin will check totals on a product by product basis

Example: in a buy three, get one free offer, the customer has four different items in their cart – one banana, one apple, one peach and one pear. If the ‘Count by’ setting is set to ‘All’, then they qualify for the offer (because they have more than three items in their cart). However, if the ‘Count by’ setting is set to ‘Product’, they don’t qualify for the offer because they don’t have any products in a quantity of three or greater.

Role settings

Roles setting for Fees and Discounts

If you’d like to apply the rule to one or more roles, then you can define the roles here.

Exclude roles

You can also choose to exclude roles. So if you wanted to offer all your customers 10% off – except Wholesale customers – you would leave the ‘Roles’ field empty, for all customers, and add the ‘Wholesale’ role to the ‘Exclude roles’ field.

Buy and Get Settings

fees discounts buy get settings

This section will display if you have chosen ‘Buy X Get X’ or ‘Buy Y Get Y’ as the rule type.

Buy

Enter how many items the customer needs to purchase to trigger the offer.

Get

Enter how many items will be discounted when the offer is triggered.

Max items

The maximum number of items that are eligible for the offer. If you want to limit the number of discounted products, enter the number here. Set to 0 to allow an unlimited number of items to qualify for the offer.

Amount Settings

This section will display if you have chosen ‘Simple’, ‘Buy X Get X’ or ‘Buy Y Get Y’ as the rule type.

Discount amount settings

Adjustment type

The ‘Adjustment type’ setting defines the type of adjustment. Choose from:

  • Fixed discount
  • Percentage discount
  • Fixed fee
  • Percentage fee

Amount

Once you’ve chosen your adjustment type, enter the value of the adjustment here. Depending on whether you have chosen a fixed or percentage adjustment, the ‘Amount’ setting will either be a price value or a percentage.

“Buy” categories

categories section

If you choose ‘Specific categories’ under ‘Applies to’, you’ll see an extra field appear. ‘Buy categories’ allows you to define which product categories are eligible for the offer. Leave empty for all categories to be eligible.

“Get” categories

get categories settings

If you’ve chosen ‘Buy X Get Y’ in ‘Offer type’ and ‘Specific categories’ in ‘Applies to’, you’ll also see the ‘Get categories’ field. This allows you to define which categories the discounted items will be drawn from.

“Buy” products

buy product settings

If you choose ‘Specific products’ under ‘Applies to’, you’ll see an extra field appear. ‘Buy products’ allows you to define which products are eligible for the offer. Leave empty for all products to be eligible.

“Get” products

get products settings

If you’ve chosen ‘Buy X Get Y’ in ‘Offer type’ and ‘Specific products’ in ‘Applies to’, you’ll also see the ‘Get products’ field. This allows you to define which products the discounted items will be drawn from.

Tiers

Tiers setting

Create pricing rules according to the quantity of product in the cart

The ‘Adjustment’ setting defines the type of adjustment. Choose from:

  • Fixed discount
  • Percentage discount
  • Fixed fee
  • Percentage fee
  • Tiered

The value in the ‘Amount’ column for each row represents the percentage or fixed amount – except when you use the ‘Tiered’ adjustment type. In that case, the value in the ‘Amount’ field is the actual product price for that tier.

There’s a tutorial on tiered pricing here.

Fixed Adjustments

Fixed adjustment setting

This setting only applies to any rules with fixed values – i.e. fixed discount or fixed fees.

Choose whether to apply fixed adjustments to the combined items or per product – e.g. if there are 10 items that qualify for a fixed discount of $5, is the discount a flat rate of $5 (all) or 10 x $5 (per product).

Message

With the ‘Message’ field, you can add some text content to your product’s short description to let the user know about any deals.

Message setting

The message will be styled to match your theme.

Message on product page

Notices

Notices appear after the user has added a product to the cart to inform them how many more items they need to purchase to qualify for a deal.

WooCommerce notices field x.jpg

Notices can contain dynamic tags which will be automatically updated:

  • {amount} – the additional amount that the user needs to spend to qualify for the discount
  • {quantity} – the additional quantity that the user needs to add to their cart to get the deal
  • {discount} – the value of the discount available
  • {label} – the text in the ‘Label’ field
  • {products} – a list of the products that qualify for the deal
  • {categories} – a list of the categories that qualify for the deal

The message will be displayed after the user adds a product to their cart. It will be styled to match your theme.

WooCommerce discount notice product x.jpg

You can enable notices for different discount rules and set default content in WooCommerce > Settings > Fees and Discounts > Notices.

More information and videos

There’s a detailed blog post about setting dynamic pricing in WooCommerce here.

Video: How to create Buy One Get One Free offers

Was this article helpful?

Related Articles