Loyalty Program and Rewards for Magento 2
- Compatibility
- 2.4.9, 2.4.8, 2.4.7, 2.4.6, 2.4.5, 2.4.4, 2.4.3, 2.4.2, 2.4.1, 2.4.0
- Hyvä theme
- Hyvä compatible
Description / Loyalty Program and Rewards for Magento 2
MAGENTO 2 · POINTS · REWARDS · RETENTION
Give customers a reason to buy again.
Kowal Loyalty & Rewards Suite
Build a loyalty program inside Magento: points, discounts, VIP tiers, and referrals share a common operation history. Grow the program in stages by matching reward rules and costs to your store.
Points ledger · Cart rewards · Program per website
HOW IT WORKS IN PRACTICE
01 · You define the program rules
You configure the program, earning rules, and point redemption rules.
02 · The customer earns and redeems points
Purchases and qualifying activities trigger the configured benefits.
03 · You control the history and results
Reports show balances, transactions, returns, and rule activity.
What does your store gain?
Explore the module features, use cases, and settings.
Magento 2 loyalty program for building repeat sales
Kowal Loyalty & Rewards Suite combines loyalty points, rewards, VIP tiers, referrals, and gamification in one system for Magento 2. The program can grow with your store — from simple points for purchases to more advanced retention scenarios.
The key element is an auditable points ledger that lets you track accruals, redemptions, expirations, adjustments, and events related to returns and credit memos.
Points and ledger
Award points for purchases and activities, control their status, and keep the operation history and business context.
Rewards and checkout
Let customers redeem points as a discount and manage coupons, vouchers, and other program rewards.
VIP and referral
Build customer tiers, bonuses, and a referral program that support store visits and acquisition of new buyers.
A loyalty program under financial control
Loyalty points affect the real value of orders, so the system should let you trace their history. The ledger makes it easier to control pending and available points, expiration, adjustments, returns, and operations related to order settlement.
Grow the program in stages
- Define the program rules and how points are awarded.
- Add point earning rules for purchases and selected activities.
- Launch rewards and the ability to redeem points during the shopping process.
- Expand retention with VIP tiers, referrals, and gamification mechanisms.
- Analyze the history of points and customer behavior.
Integrations
REST API and GraphQL let you use program data in integrations and headless solutions as well.
For which stores?
For Magento 2 stores that want to increase retention, purchase frequency, and the value of customer relationships without moving the loyalty program to a separate SaaS platform.
Key areas
- points for purchases and activities,
- history and status of points operations,
- redeeming points as a shopping benefit,
- rewards, coupons, and vouchers,
- Silver, Gold, VIP tiers and bonuses,
- referral program,
- gamification and promotional mechanics,
- reporting, REST API, and GraphQL.
One program per website
The program has a website context: you define its status, visibility, and rules for a specific website. The current model supports one active program context per website. Before launch, activate the program and the required features — simply enabling the module does not activate a program in Draft status.
Points from purchase to return
The history includes pending, available, spent, reversed, and expired points. Transactions retain the context of the customer, website, event, rule, campaign, order, and credit memo, as well as an idempotency key that limits duplicate accrual of the same operation.
Cron handles deferred activation and point expiration. Credit memo support allows accruals to be reversed and redeemed points to be restored according to the return process.
Using points as a discount
The customer can apply or remove points in the cart and checkout. The system checks membership, available balance, and configuration limits, converts points into a discount in the base currency, and saves the redemption on the order.
Before launch, set the point value and redemption limits, then verify how the discount works with taxes, promotions, and your store’s actual checkout.
VIP tiers and qualified referrals
A customer’s tier can be based on the value of completed orders from the last 12 months, the number of orders, and points earned. The value is based on the subtotal, excluding shipping. The tier bonus is added as a separate ledger transaction.
A referral uses the customer’s code and link, assignment during program enrollment, and a qualifying order status. The mechanism blocks self-referrals and reassignment of the same person; you define the reward through program rules.
Gamification with reward control
Spin the wheel and scratch card mechanics use deterministic selection or a defined sequence of results. Pools can have win and point budget limits as well as customer and email participation limits. The history records participation and the awarded reward.
Possible benefits include points, a coupon, a free shipping coupon, a badge, or no reward. Mechanic definitions can be presented in CMS widgets.
Reports and package architecture
The Composer package contains 28 modules, including program, points, rules, rewards, checkout, consents, newsletter, tiers, referrals, communication, reports, REST, and GraphQL. A standard installation uses a single suite package.
Magento Admin reports show balances, point liabilities, the ledger, and rule and campaign activity. They offer filtering, saved views, and CSV; campaign and tier bonuses can be tracked separately from base accruals.
Optional Hyvä support
The suite includes the Kowal_LoyaltyHyva adapter for product pages, cart, minicart, enrollment form, customer account, and widgets. Rendering is disabled by default and requires an active Hyvä theme and program configuration.
In Hyvä checkout, the form uses a standard POST with page reload and the shared Magento discount collector. The adapter does not include a dedicated Magewire component or Hyvä Checkout summary row; custom checkout and cart implementations require integration verification.
Installation with Composer
Package kowal/metapackage-loyalty-suite, module Kowal_Loyalty. After configuring access to the Kowal repository, install the package, enable the module, update Magento, and clear the cache. In production, include compilation and static content deployment according to your store’s process.
From configuration to results
1. You define the program rules
You configure the program, earning rules, and point redemption rules.
2. The customer earns and redeems points
Purchases and qualifying activities trigger the configured benefits.
3. You control the history and results
Reports show balances, transactions, returns, and rule activity.
Example: from points to VIP tiers
You start with points for purchases and a cart discount. Then you add Silver, Gold, and VIP thresholds as well as referrals qualified after an order. Every accrual and bonus remains linked to the program history.
Design a program customers come back to.
Want to adapt the module to your store? Ask about implementing Kowal Loyalty & Rewards Suite and discuss the configuration or required extensions.
More Information
| Hyvä theme | Hyvä compatible |
|---|---|
| Theme compatibility | Hyvä, Luma / Blank, KOWAL |
Module Installation Instructions
Installation and configuration guide for Kowal Loyalty & Rewards Suite
This document describes the installation and basic configuration of the kowal/metapackage-loyalty-suite package in Magento 2. The guide is based on the current module code, system.xml configuration, config.xml default values, and product documentation.
Requirements
- Magento Open Source
2.4.9or a compatible Magento 2.4.x installation. - PHP
^8.3. - Access to the Magento server console.
- Magento cron enabled.
- At least one website, store, and store view configured.
- Active Magento modules used by the package, including Customer, Sales, Quote, Checkout, CMS, Newsletter, SalesRule, Webapi, GraphQl, UI, and ImportExport.
The package is installed as one Composer root package. Submodules are located in packages/, but a standard installation does not require installing them separately.
Installation
In your Magento project, run:
You will receive the Composer repository access credentials, the customer email address and license token, by email after purchase. They are also available in the customer panel after logging in at kowal.store. Replace TWOJ_EMAIL_KLIENTA with your account email address and TWOJ_TOKEN with the token you received. Run the commands in the Magento root directory.
composer config repositories.kowal composer https://repo.kowal.storecomposer config http-basic.repo.kowal.store 'TWOJ_EMAIL_KLIENTA' 'TWOJ_TOKEN'composer require kowal/metapackage-loyalty-suite:^0.1bin/magento module:enable Kowal_Loyalty Kowal_LoyaltyProgram Kowal_LoyaltyRules Kowal_LoyaltyPoints Kowal_LoyaltyRewards Kowal_LoyaltyCheckout Kowal_LoyaltyEnrollment Kowal_LoyaltyConsent Kowal_LoyaltyNewsletter Kowal_LoyaltyContent Kowal_LoyaltyTiers Kowal_LoyaltyCampaigns Kowal_LoyaltyWallet Kowal_LoyaltyCoupons Kowal_LoyaltyChallenges Kowal_LoyaltyBadges Kowal_LoyaltyLeaderboard Kowal_LoyaltyReferrals Kowal_LoyaltyGamification Kowal_LoyaltyLottery Kowal_LoyaltyCommunication Kowal_LoyaltyReports Kowal_LoyaltyAdminUi Kowal_LoyaltyApi Kowal_LoyaltyGraphQl Kowal_LoyaltyImportExport Kowal_LoyaltyIntegrationbin/magento setup:upgradebin/magento cache:flushAfter installation, verify that Magento cron is working correctly. Cron is required, among other things, to activate pending points, expire points, send notifications, and refresh rankings.
Local package validation
In the package repository, you can run:
./scripts/validate-local.shThe script checks basic JSON, PHP, PHTML, and XML files, module registrations, and GraphQL schemas.
Configuration location in the Magento panel
The main configuration is located under:
Stores > Configuration > Kowal > Loyalty & RewardsThe configuration is mostly scoped per website. This means the program can be enabled for one website and left disabled for another.
General
| Field | Config path | Default | Meaning |
|---|---|---|---|
| Enable Loyalty | kowal_loyalty/general/enabled | No | Enables the loyalty program for the selected website. Without this, domain modules should not handle the customer as a participant in an active program. |
| Debug Mode | kowal_loyalty/general/debug | No | Enables additional diagnostics for the selected website. Use on staging or when analyzing issues. |
| Log Retention Days | kowal_loyalty/general/log_retention_days | 30 | Global retention period for loyalty logs in days. |
Recommendation: in production, set Enable Loyalty = Yes only for the website where the program should be active. Leave Debug Mode as No unless you are diagnosing a specific issue.
Program
| Field | Config path | Default | Meaning |
|---|---|---|---|
| Program ID | kowal_loyalty/program/program_id | default | Internal program identifier. The MVP assumes one program per website. Most often, leave default. |
| Program Name | kowal_loyalty/program/name | Loyalty & Rewards | Program name visible to the customer in widgets, the landing page, and the account panel. |
| Short Description | kowal_loyalty/program/short_description | Earn points, unlock rewards and use them on future orders. | Short program description used in frontend presentation. |
| Program Status | kowal_loyalty/program/status | draft | Program status. Only an active program is treated as available to customers. |
| Program Visibility | kowal_loyalty/program/visibility | public | Controls program visibility in the storefront layer. |
| Program Terms CMS Page | kowal_loyalty/program/program_terms_cms_page | 0 | CMS page with the loyalty program terms. The link can be used automatically by forms and widgets. |
| Store Terms CMS Page | kowal_loyalty/program/store_terms_cms_page | 0 | CMS page with the store terms, required especially for guest enrollment and account creation. |
Recommendation: before enabling the program publicly, create CMS pages with the program terms and store terms, then assign them in the configuration.
Points Defaults
| Field | Config path | Default | Meaning |
|---|---|---|---|
| Default Points Expiration Days | kowal_loyalty/points/expiration_days | 365 | Number of days points remain valid, counted from the activation date. |
| Default Rounding Mode | kowal_loyalty/points/rounding_mode | floor | Point rounding method: down, standard, or up. |
| Default Earning Amount Basis | kowal_loyalty/points/earning_amount_basis | base_row_total_incl_tax_after_discount | Order value basis used for point accrual. Shipping is always excluded. |
| Earn Points After Order Status | kowal_loyalty/points/earning_order_status | complete | Order status after which purchase points are awarded. |
| Activate Pending Points After Order Status | kowal_loyalty/points/activation_order_status | complete | Order status after which pending points can become available. |
| Activation Delay Days | kowal_loyalty/points/activation_delay_days | 0 | Additional delay for point activation. 0 means activation without delay after the status condition is met. |
| Expiration Notification Days | kowal_loyalty/points/expiration_notification_days | 30,7,1 | Notification thresholds before point expiration, separated by commas. |
Default Earning Amount Basis options:
| Value | Meaning | When to use |
|---|---|---|
base_row_total_incl_tax_after_discount | Gross amount after discounts | The most common B2C option, where the customer earns points on the real paid value of products. |
base_row_total_incl_tax_before_discount | Gross amount before discounts | When price promotions should not reduce the number of points earned. |
base_row_total_after_discount | Net amount after discounts | For B2B or stores that settle loyalty based on net value. |
base_row_total_before_discount | Net amount before discounts | For programs calculated from the catalog net value of products. |
Recommendation: for a typical B2C store, leave Gross After Discounts, rounding_mode = floor, complete statuses, and point validity of 365 days.
Point Redemption
| Field | Config path | Default | Meaning |
|---|---|---|---|
| Points | kowal_loyalty/redemption/points | 100 | Number of points corresponding to the configured discount amount. |
| Discount Amount | kowal_loyalty/redemption/base_amount | 10 | Discount amount in the website base currency for the specified number of points. |
| Minimum Points To Redeem | kowal_loyalty/redemption/min_points | 100 | Minimum number of points the customer can redeem in the cart. |
| Minimum Order Amount | kowal_loyalty/redemption/min_order_amount | 100 | Minimum order value qualifying for point redemption. Shipping is excluded from the validation basis. |
| Maximum Order Percent Paid With Points | kowal_loyalty/redemption/max_order_percent | 30 | Maximum percentage of the qualifying order value that can be paid with points. |
Example: values Points = 100 and Discount Amount = 10 mean that 100 points gives a discount of 10 units of the base currency. With Maximum Order Percent Paid With Points = 30, the customer can cover up to 30% of the qualifying cart value with points.
Recommendation: at the start, set a conservative limit, e.g. 20-30%, so the program does not consume the entire order margin.
Feature Flags
| Field | Config path | Default | Meaning |
|---|---|---|---|
| Program | kowal_loyalty/features/program | Yes | Enables the program layer and website context. |
| Rules | kowal_loyalty/features/rules | No | Enables point earning rule support. |
| Points | kowal_loyalty/features/points | No | Enables the points ledger and balance projection. |
| Rewards | kowal_loyalty/features/rewards | No | Enables reward and point redemption mechanisms. |
| Checkout | kowal_loyalty/features/checkout | No | Enables integration with the cart and checkout. |
| Content | kowal_loyalty/features/content | No | Enables the content layer, landing pages, widgets, and frontend blocks. |
| Leaderboard | kowal_loyalty/features/leaderboard | No | Enables customer ranking if the module is installed. |
| Gamification | kowal_loyalty/features/gamification | No | Enables deterministic promotional mechanics. |
| Lottery | kowal_loyalty/features/lottery | No | Enables the lottery and games of chance module. |
Feature flags let you launch the package in stages. For the first configuration, usually enable: Program, Rules, Points, Rewards, Checkout, and Content.
Leaderboard
| Field | Config path | Default | Meaning |
|---|---|---|---|
| Enable Leaderboard | kowal_loyalty/leaderboard/enabled | No | Enables ranking materialization by cron. Leave disabled until privacy rules are accepted. |
| Allow Public Leaderboard Widgets | kowal_loyalty/leaderboard/public_enabled | No | Allows public ranking widgets to be displayed. When disabled, widgets do not render a public ranking. |
| Default Metric | kowal_loyalty/leaderboard/default_metric | points | Default ranking metric: points, challenge progress, referrals, or reviews. |
| Default Widget Limit | kowal_loyalty/leaderboard/default_limit | 10 | Number of positions in widgets. The code limits the value to a maximum of 100. |
Recommendation: use public rankings only when you have an accepted privacy policy and customer communication. By default, the module uses pseudonyms instead of personal data.
Gamification
| Field | Config path | Default | Meaning |
|---|---|---|---|
| Enable Gamification Mechanics | kowal_loyalty/gamification/enabled | No | Enables deterministic promotional mechanics, such as Spin the Wheel and Scratch & Win. |
| Gamification feature flag | kowal_loyalty/features/gamification | No | Feature flag for the gamification area. |
Gamification mechanics are not a real lottery. Reward selection is deterministic or based on a defined sequence, which makes legal and budget control easier.
Lotteries and Games of Chance
| Field | Config path | Default | Meaning |
|---|---|---|---|
| Enable Lottery Module | kowal_loyalty/lottery/enabled | No | Enables the lottery module. Leave disabled without prior legal verification. |
| Allow Public Lottery Widgets | kowal_loyalty/lottery/public_widgets_enabled | No | Allows public widgets for active campaigns with legal approval to be rendered. |
| Lottery feature flag | kowal_loyalty/features/lottery | No | Feature flag for the lottery area. |
Recommendation: for regular promotions, use Gamification. Enable Lottery only for campaigns that have separate terms, legal approval, and a country scope compliant with regulations.
Point rules
Point rules are managed in the module’s admin panel. Their form includes:
| Field | Meaning |
|---|---|
| Enabled | Whether the rule is active. |
| Program ID | The program the rule applies to. In the MVP, usually default. |
| Name | Rule name visible in administration. |
| Description | Auxiliary description for the administrator. |
| Event Type | Event for which points are awarded, e.g. purchase, newsletter, referral. |
| Points Mode | Point accrual method, e.g. fixed value or value based on amount. |
| Points Value | Number of points or conversion rate used by the selected mode. |
| Priority | Evaluation order. Rules matching the event are cumulative; priority does not stop subsequent rules. |
| Related Landing Page Identifier | Identifier of the CMS page associated with the rule. |
| Website IDs | Comma-separated list of website IDs. An empty field means all websites. |
| Customer Group IDs | Comma-separated list of customer group IDs. An empty field means all groups. |
| From Date / To Date | Rule validity period. |
Example of a simple purchase rule: Event Type = purchase, Points Mode = amount based, Points Value = 1, active for all groups and only for the selected website. This means points are awarded according to cart value based on the basis from the Points Defaults configuration.
Example newsletter bonus: Event Type = newsletter_signup, Points Mode = fixed, Points Value = 50, period without an end date. The rule awards a one-time bonus after the customer subscribes to the newsletter if the newsletter integration triggers the appropriate event.
Customer tiers
Tiers are managed as admin entities. The tier form includes:
| Field | Meaning |
|---|---|
| Enabled | Whether the tier is active. |
| Program ID | The program the tier applies to. In the MVP, usually default. |
| Name | Tier name, e.g. Silver, Gold, VIP. |
| Code | Technical tier code. |
| Sort Order | Tier order. |
| Minimum Completed Purchase Amount | Minimum value of completed orders from the last 12 months, excluding shipping. |
| Minimum Completed Orders | Minimum number of completed orders. |
| Minimum Earned Points | Minimum number of points earned. |
| Bonus Multiplier | Bonus multiplier. 1.25 means a separate bonus transaction of +25% relative to base points. |
| Website IDs | Comma-separated list of website IDs. An empty field means all websites. |
Default tiers installed as templates:
| Tier | Purchase threshold | Multiplier |
|---|---|---|
| Silver | 1000 | 1.25 |
| Gold | 3000 | 1.5 |
| VIP | 7500 | 2.0 |
Treat the default values as a starting point. Before production, adjust thresholds to the average order value, margin, and purchase frequency.
Configuration examples
1. Simple points program for a B2C store
Goal: the customer collects points for purchases and can spend them in the cart.
Settings:
Enable Loyalty = Yes.Program Status = active.Program Visibility = public.Program Terms CMS PageandStore Terms CMS Pagepoint to the correct CMS pages.Default Earning Amount Basis = Gross After Discounts.Earn Points After Order Status = complete.Activate Pending Points After Order Status = complete.Activation Delay Days = 0.Default Points Expiration Days = 365.Points = 100,Discount Amount = 10.Minimum Points To Redeem = 100.Minimum Order Amount = 100.Maximum Order Percent Paid With Points = 30.- Feature flags:
Program,Rules,Points,Rewards,Checkout,Contentset toYes.
Add a point rule for purchases and test the entire flow: enrollment, order, point accrual, and using points in the cart.
2. Program with delayed point activation
Goal: points become available only after the return period.
Settings:
Earn Points After Order Status = complete.Activate Pending Points After Order Status = complete.Activation Delay Days = 14or30.Default Points Expiration Days = 365.Expiration Notification Days = 30,7,1.
This option reduces the risk that the customer spends points before the return period ends.
3. B2B program calculated on net value
Goal: award points on the net product value, excluding shipping and tax.
Settings:
Default Earning Amount Basis = Net After Discounts.Default Rounding Mode = floor.- Set
Minimum Order Amountaccording to the minimum B2B order value, e.g.500. - Set
Maximum Order Percent Paid With Pointsconservatively, e.g.10or20.
This option makes sense when loyalty should be settled closer to margin and the invoiced net value.
4. VIP program with customer tiers
Goal: better customers earn additional points.
Settings:
- Enable the basic feature flags for the program, points, rules, and checkout.
- Configure tiers, e.g. Silver, Gold, VIP.
- Set
Bonus Multiplier:1.25,1.5,2.0. - Adjust
Minimum Completed Purchase Amountthresholds to sales data.
The tier bonus is saved as a separate transaction in the ledger. This allows reports to separate base points from bonus points.
5. Campaign with ranking
Goal: display a public customer ranking in a campaign.
Settings:
Leaderboard feature flag = Yes.Enable Leaderboard = Yes.Default Metric = points,challenge_progress,referrals, orreviews.Default Widget Limit = 10or another reasonable value.Allow Public Leaderboard Widgets = Yesonly after privacy rules are accepted.
Before publication, check the terms content, privacy policy, and the way customer aliases are presented.
6. Spin the Wheel promotion without a lottery
Goal: a controlled promotional campaign with rewards without a random mechanism.
Settings:
Gamification feature flag = Yes.Enable Gamification Mechanics = Yes.- Do not enable
Lotteryif the promotion is not legally a lottery. - Use deterministic mechanics or a predefined reward sequence.
- Set limits for customer participation, email participation, point budget, and number of wins in the mechanic configuration.
This option is appropriate for marketing campaigns that should look attractive but must remain budget-controlled and auditable.
7. Lottery or game of chance
Goal: launch a campaign with a real random element.
Settings:
Lottery feature flag = Yes.Enable Lottery Module = Yes.Allow Public Lottery Widgets = Yesonly after preparing the campaign.- The campaign must have active status, the correct website and country scope, and
legal_approval_status = approved. - Add separate CMS terms and a campaign landing page.
Do not use this option without legal verification for the country in which the store operates.
Pre-production checklist
- Program enabled only for the correct websites.
- Program status set to active.
- Program terms and store terms assigned to CMS pages.
- Newsletter clearly described as a condition for full program rights.
- Point rules checked on staging.
- Point redemption limits calculated against margin.
- Returns and credit memos tested manually.
- Magento cron is running and processes pending points, expiration, and rankings.
- Public rankings and lotteries legally approved.
- REST API and GraphQL checked for access only to the correct customer data.
- Point adjustment import tested for idempotency.
Useful locations in the panel
Stores > Configuration > Kowal > Loyalty & Rewards- main program configuration.Customers > Loyalty & Rewardsor theKowal Loyaltyadmin menu - participants, ledger, manual adjustments, and reports, depending on enabled modules.- CMS Pages - program terms, store terms, and landing pages.
- Cart Price Rules - discount rules used by coupon rewards.
Operational notes
The points ledger is the source of truth. The balance table is a projection for fast reads in the frontend, checkout, and admin panel. Balances should not be edited manually without a ledger transaction.
Point rules are cumulative. If several active rules match an event, the customer can receive several separate point transactions. Rule priority controls the order and audit readability, not the stopping of further rules.
Points redeemed in the cart are saved on the quote, transferred to the order, and settled after order placement. Returns and credit memos should be tested for full and partial refunds, especially when the store uses points as a discount.