Discount based on Purchase History

Discover how to provide discounts based on customer’s purchase history using Discount Rules for Woocommerce plugin.

Sangeetha avatar
Written by Sangeetha
Updated over a week ago

Introduction:

A purchase history based discount is a type of discount or offer provided to customers based on their previous purchase behaviour.

For example: Offer a 10% discount on all products for customers who have made more than five previous orders.

The Discount Rules for WooCommerce plugin enables personalised discounts based on a customer's past purchases, encouraging repeat business and enhancing customer satisfaction. The available purchase history based conditions are:

  • First order

  • Last order

  • Last order amount

  • Number of orders made

  • Number of orders made with the following products

  • Number of quantities made with the following products and

  • Total spent

Note: All these conditions will be in Rules(optional). You can select your desired condition and set the rules.

Pre-requisites / Requirements:

This is a special type of discount scenario, which only works under certain circumstances.

So carefully read the points below :

The scenario requires validating the below points:
- whether the visitor is a returning customer or a first time visitor
- And we need to check the purchase history to ensure he has orders placed previously
To establish the above facts, we need the visitor to either register and log in. (Example: Purchase history can be validated only for a registered/logged in user)

When a visitor comes to your site, there is ABSOLUTELY NO WAY of knowing whether he is

  • A first time visitor or

  • A returning customer

The ONLY way to establish and validate whether he is a first timer or a returning customer is "when he logs in"

Only when he is logged in, we can

  • retrieve his previous purchase history based on customer's Email ID or User ID

  • if there is a previous purchase, he is a returning customer

  • If there is no purchase, he is a new, first time customer

As a result, this discount scenario can only be run:

  1. When customer logs in

  2. Only at the checkout

As a result, the scenario will show the discount only after the customer logs in. Not before that because we may know who the visitor is (a returning customer or a first timer)

Here are the example scenarios for each condition:

  • First order: Offer a 10% discount on the customer's first order as a welcome gift.

  • Last order: Give a free gift for the next order to customers who placed their last order within the past 7 days.

  • Last order amount: Provide a $5 discount from the whole cart on the next purchase if the customer's last order amount exceeds $50.

  • Number of orders made: Give a $10 discount from cart on the next purchase for customers who have made at least five orders in total.

  • Number of orders made with the following products: Offer a 20% discount on a specific product if the customer has made three or more orders containing that product in the current month.

  • Number of quantities made with the following products: Provide a 15% discount on a specific product if the customer has purchased ten or more quantities of that product in their previous orders.

  • Total spent: Offer a 5% discount on all products if the customer's total spent across all orders exceeds $500.

To create discount rules with Purchase History based conditions, you need to have the Discount Rules PRO plugin installed and activated. You can purchase the PRO version by clicking on the provided button.

Now, let's take a closer look at each example in detail.

Example 1: First order: Offer a storewide 15% discount on the customer's first order as a welcome offer

This discount offers New customers a 15% discount on all products throughout the store. This offer encourages them to become regular customers on your site, fostering a strong relationship.

Creating a Discount Rule:

  • Go to WordPress dashboard -> Woocommerce -> Discount Rules -> Click on “Add New Rule” button

  • Select the discount types as “Product Adjustment”

Then configure the discount rule as seen in the below screenshot:

Details of configurations are:

  • Choose "All Products" (storewide) from the filter options. You also have options like specific Categories, selected Products, Attributes, Tags, Sku’s and so on… You can choose the option depending upon your requirement.

  • Set the discount type to a 15% percentage discount. You also have options to choose Fixed discount or Fixed discount per product

  • Include “First Order” as additional condition and set it as “Yes”

  • Click on “SAVE” once we have successfully created the rule.

First-time customers will now receive a store-wide 10% discount on their initial purchase.

Here is the cart page screenshot of a first-time customer :

Example 2: Last order: Give a free gift for the next order to customers who placed their last order within the past 7 days

With this discount, customers who have placed an order in the last 7 days will receive a free gift with their next purchase. This enticing offer is designed to motivate customers to make frequent purchases and enjoy the added value of a complimentary product.

Creating a Discount Rule:

  • Go to WordPress dashboard -> Woocommerce -> Discount Rules -> Click on “Add New Rule” button

  • Select the discount types as “Buy X Get Y”

Then configure the discount rule as seen in the below screenshot:

Details of configurations are:

Step 1: Choose "All Products" (storewide) from the filter options (buy X section). You also have options like specific Categories, selected Products, Attributes, Tags, Sku’s and so on… You can choose the option depending upon your requirement.

Step 2: Choose “Buy X get Y - Products” in the Discount/ Get Y section. You also have other options like “Buy X Get Y - All” or “Buy X Get Y - Categories or Buy X Get Y - Collections” depending on your requirement.

Step 3: Choose how to count the quantities as -> Filter set above (count all quantities in cart as together. For example, if a customer buys 2 of Product A and 3 of Product B, our plugin count 5 products as together)

Step 4: Select the mode of application as

  • Autoadd

  • Set minimum quantity as 1, leave maximum quantity section as empty, set free quantity as 1 and select the product “Bag” by typing few characters of the product in Discount/ Get Y section

  • Choose the discount type as FREE (you can also set Percentage or Fixed Discount) and

Step 5: Add additional conditions as "Last order" and configure the condition as shown above. You also have options to choose the time period and order status as per your requirement.

Step 6: Save the rule.

Now, customers who have placed their last order within the current week will automatically receive a complimentary "Bag" product added to their cart.

Here is a screenshot demonstrating the "Bag" product being automatically added for a customer who completed their last order within this week:

Example 3: Last order amount: Provide a 5% discount from the whole cart on the next purchase if the customer's last order amount exceeds $50

In this example, customers will get a 5% off from the cart if their last order amount is greater than $50.

Creating a Discount Rule:

  • Go to WordPress dashboard -> Woocommerce -> Discount Rules -> Click on “Add New Rule” button

  • Select the discount types as “Cart Adjustment”

Then configure the discount rule as seen in the below screenshot:

Details of configurations are:

  • Choose "All Products" (storewide) from the filter options. You also have options like specific Categories, selected Products, Attributes, Tags, Sku’s and so on… You can choose the option depending upon your requirement.

  • Set the discount type to a 5% percentage discount. You also have options to choose Fixed discount or Fixed discount per product

  • Set the Discount Label as “5% off”

  • Add the additional condition as "Last order amount" and set the order amount to be greater than or equal to 50.

  • Additionally, choose the order status that will be considered as successful orders to fulfill this condition. For example: Processing and Completed

  • Click on “SAVE” once we have successfully created the rule.

Now, customers will receive a 5% discount from the cart if their previous order amount is $50 or more.

Below is the screenshot of the cart page displaying a 5% off discount applied, as my previous order totaled $50:

Example 4: Number of orders made: Give a $10 discount from cart on the next purchase for customers who have made at least five orders in total

In this scenario, customers who have made a minimum of five orders on your site will be eligible for a $10 discount from cart.

Creating a Discount Rule:

  • Go to WordPress dashboard -> Woocommerce -> Discount Rules -> Click on “Add New Rule” button

  • Select the discount types as “Cart Adjustment”

Then configure the discount rule as seen in the below screenshot:

Details of configurations are:

  • Choose "All Products" (storewide) from the filter options. You also have options like specific Categories, selected Products, Attributes, Tags, Sku’s and so on… You can choose the option depending upon your requirement.

  • Set the discount type to a $10 Fixed Discount. You also have options to choose Percentage discount or Fixed discount per product

  • Set the Discount Label as “$10 off”

  • Add the following additional condition: "Number of orders made." The orders can be placed at any time “All time”, and the order quantity should be greater than or equal to 5.

  • Furthermore, select the order statuses that will be considered as successful orders to meet this condition, such as Processing, On-hold, and Completed.

  • Click on “SAVE” once we have successfully created the rule.

Now, customers will now receive a fixed $10 discount from the cart if they have previously completed a minimum of 5 orders so far.

Here is a screenshot of the cart page, displaying a $10 discount that has been applied because I have completed a total of 5 orders so far:

Example 5: Number of orders made with the following products: Offer a 20% discount on a specific product if the customer has made three or more orders containing that product in the current month.

In this scenario, customers will receive a 20% discount on a specific product, namely "Bag," if they have previously purchased this product with any quantity in at least three or more different orders within the current month.

Creating a Discount Rule:

  • Go to WordPress dashboard -> Woocommerce -> Discount Rules -> Click on “Add New Rule” button

  • Select the discount types as “Product Adjustment”

Then configure the discount rule as seen in the below screenshot:

Details of configurations are:

  • Choose "Products” from the filter options and type a few characters of the products name to find your product and select it. You also have options like specific Categories, selected Attributes, Tags, Sku’s and so on… You can choose the option depending upon your requirement.

  • Set the discount type to a 20% percentage discount. You also have options to choose Fixed discount or Fixed price per product

  • Include additional conditions such as “Number of orders made with following products” and select the same product “Bag’ in condition by typing few characters of the product, set the purchase before parameter as “Current month” and order quantity should be as greater than or equal to 3.

  • Then, you have the flexibility to choose the order statuses that will be considered as successful orders to fulfill this condition. For example, you can select "Processing" and "Completed" as successful order statuses, or you may opt for other order statuses based on your specific requirements that should be considered as successful.

  • Click on “SAVE” once we have successfully created the rule.

Now, customers will receive 20% off on the specific product “Bag”, if the customer has previously purchased any quantities of the same product in a minimum of three or more different orders in the current month.

This screenshot displays the cart page with a 20% discount applied to the "Bag" product. The discount has been granted because I have purchased the same product in three different orders within the current month :

Example 6: Number of quantities made with the following products: Provide a 15% discount on a specific product if the customer has purchased ten or more quantities of that product in their previous orders.

In this example, customers will receive a 15% discount on a specific product if they have purchased ten or more quantities of that product in any of their previous orders.

Creating a Discount Rule:

  • Go to WordPress dashboard -> Woocommerce -> Discount Rules -> Click on “Add New Rule” button

  • Select the discount types as “Product Adjustment”

Then configure the discount rule as seen in the below screenshot:

Details of configurations are:

  • Choose "Products” from the filter options and type a few characters of the products name to find your product and select it. You also have options like specific Categories, selected Attributes, Tags, Sku’s and so on… You can choose the option depending upon your requirement.

  • Set the discount type to a 15% percentage discount. You also have options to choose Fixed discount or Fixed price per product

  • Include additional conditions such as “Number of quantities made with following products” and select the same product “Bag’ in condition by typing few characters of the product, set the purchase before parameter as “All time” and product quantity should be as greater than or equal to 10.

  • Then, you have the flexibility to choose the order statuses that will be considered as successful orders to fulfill this condition. For example, you can select "Processing" and "Completed" as successful order statuses, or you may opt for other order statuses based on your specific requirements that should be considered as successful.

  • Click on “SAVE” once we have successfully created the rule.

Customers will now enjoy a 15% discount on the specific product "Bag" if they have previously purchased 10 or more quantities of the same product across any number of orders.

Please find the attached screenshot of the cart page, displaying the applied discount:

Example 7: Total spent: Offer a 5% discount on all products if the customer's total spent across all orders exceeds $500

In this example, customers will receive a 5% discount on all products in the store if their total spent across all previous orders exceeds $500.

Creating a Discount Rule:

  • Go to WordPress dashboard -> Woocommerce -> Discount Rules -> Click on “Add New Rule” button

  • Select the discount types as “Product Adjustment”

Then configure the discount rule as seen in the below screenshot:

Details of configurations are:

  • Choose "All Products" (storewide) from the filter options. You also have options like specific Categories, selected Products, Attributes, Tags, Sku’s and so on… You can choose the option depending upon your requirement.

  • Set the discount type to a 5% percentage discount. You also have options to choose Fixed discount or Fixed price per item

  • Include additional conditions such as “Total spent” and set the total purchase amount should be as greater than or equal to $500 (all time)

  • Then, you have the flexibility to choose the order statuses that will be considered as successful orders to fulfill this condition. For example, you can select "Processing" and "Completed" as successful order statuses, or you may opt for other order statuses based on your specific requirements that should be considered as successful.

  • Click on “SAVE” once we have successfully created the rule.

Now, customers will now receive a 5% discount on all products in the store if they have previously spent a total of $500 or more across any number of orders.

Please find the attached screenshot of the cart page, displaying the applied discount:

The above discussed scenarios require a PRO version.

Note:

  • Number of orders made with following products - Here the count will be based on orders made with the respective product.

  • Number of quantities made with following products - Here the count will be based on the quantities made with the respective product.

  • The only way to know whether he is first time customer/ returning customer -> to check order count, we use EMAIL ID or customer's USER ID as a unique identifier. If a customer placed 5 orders using the same email address, then customers "Number of Order made count is -> 5 for example.

Next Steps:

You may also want to check out these helpful guides:

Check out the following video tutorial to know about purchase history condition:

Still unclear ?

Please submit a support request. We are always happy to assist you :)

Did this answer your question?