Pricing Rule
A Pricing Rule defines automatic pricing and discount conditions that are applied to items based on defined business rules such as quantity, customer group, item group, date, or transaction conditions.
It helps automate pricing decisions and ensures consistent pricing across sales and purchase transactions.
Pricing Rules are commonly used for promotions, customer-specific pricing, quantity-based discounts, and dynamic rate adjustments without manually editing item prices in each transaction.
1. Prerequisites
Before creating a Pricing Rule, ensure the following masters are created so rules can be applied correctly:
- Item – The product on which pricing rules will apply.
- Item Group – Used for applying rules to a category of items.
- Customer – Required for customer-specific pricing rules.
- Supplier – Required for supplier-based pricing rules.
Pricing Rules depend on master data like Items and Customers to correctly evaluate conditions during transactions.
2. How to create a Pricing Rule
- Go to Pricing Rule and click New.
- Enter a meaningful title for identification.
- Select Apply On (Item Code, Item Group, Brand, or Transaction).
- Choose rule type: Price Rule or Product Discount.
- Select specific items or item groups depending on scope.
- Define pricing logic such as rate, discount %, or discount amount.
- Save the rule to activate it.
Once saved, ERPNext automatically applies the Pricing Rule during transaction entry when conditions match.
3. Additional Options
3.1 Warehouse
Restricts the Pricing Rule to apply only when items are selected from a specific warehouse.
3.2 Apply Rule On
- Item – Applies to specific item codes.
- Item Group – Applies to a category of items.
- Brand – Applies based on item brand.
- Transaction – Applies based on total transaction value.
3.3 Condition
Custom Python-style conditions can be used to control when the rule applies.
customer=='Customer Name' and status!='Overdue'
3.4 Mixed Conditions
Allows pricing rules to apply based on combined quantity across multiple items instead of individual item quantities.
3.5 Is Cumulative
Enables rule application across multiple transactions until a total amount threshold is reached.
4. Pricing Rule Features
4.1 Apply Rule On Other
Allows a rule triggered by one item to be applied on a different item, useful for promotional combinations.
4.2 Party Information
- Customer / Customer Group
- Supplier / Supplier Group
- Territory
- Sales Partner / Campaign
4.3 Quantity and Amount Conditions
Rules can be restricted based on minimum or maximum quantity and transaction value.
4.4 Validity
Defines a date range during which the Pricing Rule is active, commonly used for promotions.
4.5 Margin
Automatically calculates selling price based on a defined margin percentage or fixed amount.
4.6 Price Discount Scheme
- Rate – Overrides item price with a fixed value.
- Discount Percentage – Applies percentage-based discount.
- Discount Amount – Applies fixed discount value.
4.7 Advanced Settings
- Threshold for Suggestion – Suggests quantity adjustment for discounts.
- Priority – Controls rule precedence when multiple rules apply.
- Apply Multiple Pricing Rules – Combines multiple discounts.
- Apply Discount on Rate – Applies compounded discount effect.
- Validate Applied Rule – Ensures compliance with defined pricing logic.
5. Pricing Rule Types
5.1 Price Discount
Directly modifies item price using rate or discount rules, overriding standard price list values when conditions match.
5.2 Product Discount
Provides free items instead of price reduction.
- Buy 2 get 1 free (same item)
- Buy X get Y free (different item)
ERPNext enforces product discounts automatically, but can be relaxed using the “Don’t Enforce Free Item Qty” option.
6. Key Benefits
- Automates discount and pricing logic.
- Reduces manual price adjustments.
- Enables promotional and customer-specific pricing.
- Improves pricing consistency across transactions.
7. Related Topics
- Promotional Scheme
- Tax Rule
- Item
- Customer
- Supplier