Skip to main content
Drupal is a registered trademark of Dries Buytaert
Release: Trash 3.0.33 Minor update available for module trash (3.0.33). EOL Warning: Drupal 11.0 has reached end of life and no longer receives security updates. EOL Warning: Drupal 10.3 has reached end of life and no longer receives security updates. Release: UI Patterns (SDC in Drupal UI) 2.0.20 Minor update available for module ui_patterns (2.0.20). Release: Trash 3.1.0-rc1 First release candidate for module trash (3.1.0-rc1). Release: Country 2.2.0 Minor update available for module country (2.2.0). Usage Milestone: jQuery UI Datepicker Module jquery_ui_datepicker crossed 1,000 active installs. Release: Scheduler Content Moderation Defaults 1.1.2 Minor update available for module scheduler_content_moderation_defaults (1.1.2). Release: Flags 2.1.0 Minor update available for module flags (2.1.0). Release: Login Disable 2.2.0 Minor update available for module login_disable (2.2.0).

Commerce Loyalty Condition adds a promotion condition that matches customers by their own order history rather than by the order in front of them. Use it to reward returning customers: a discount from the third order onwards, free shipping for anyone who has spent over a threshold, an offer aimed at customers who bought recently.

The condition is called Limit by number of orders and appears under the Customer tab wherever Drupal Commerce offers conditions on an order. It takes three settings, and the last two are optional:

  • How many completed orders the customer must already have.
  • A time window, so that only orders completed within the last N days count. Leave it empty to count the customer's whole history.
  • A minimum total, so those orders must add up to at least a given amount. The comparison is inclusive.

Two things worth knowing before configuring it. Only completed orders are counted, so carts and other drafts are ignored. And the condition never matches a guest checkout, because every guest shares the anonymous user account and would otherwise inherit the order history of everyone who checked out without one.

Requirements

Full documentation is in the README. Bug reports and feature requests are welcome in the issue queue.

Depends on

Dependencies of the latest stable release

Required by

Tracked projects that depend on this one

No tracked projects depend on this one yet.

Activity

Tracked releases
1
Tracked since
Aug 2026
Latest release
1 hour ago
Releases (12 mo)
1 ▲ from 0
Maintenance
Active

Releases

Version Type Core Release date
1.0.0 Stable 10–11 Aug 28, 2026