Beziworld Lowest Price History for WooCommerce

By beziworld

0+ active installationsVersion 1.0.1

EU Omnibus price history for WooCommerce: the lowest price from the 30 days before a discount on product pages, variations, lists, blocks and cart.

Description

Beziworld Lowest Price History for WooCommerce records every price change of your WooCommerce products and shows the lowest price from the 30 days before the current discount, as the EU Omnibus Directive (Directive (EU) 2019/2161, Article 6a of Directive 98/6/EC) requires for announced price reductions. Everything is free: no Pro version, no locked features, no license key.

A history you can rely on

  • A dedicated, indexed database table. One row per price state with its start and end, written only when the price, the sale or the availability changes, so the table stays small even for large catalogues.
  • Regular and sale price of simple products and of every variation, with tax-inclusive or tax-exclusive prices exactly as entered.
  • Recorded from every path: product editor, quick edit, bulk edit, WooCommerce REST API, WP-CLI, the WooCommerce CSV importer, product duplication, scheduled sales and any importer that saves products the WooCommerce way. Code that writes the price meta directly or only changes the post status is caught at the end of the request.
  • The source of every change is stored (editor, quick edit, REST, CSV import, scheduled sale, Beziworld Dropshipping XML, WP All Import, starting history and more).
  • Scheduled sales are dated at their planned start and end, even when the daily WooCommerce job runs late. An hourly check records sales that started or ended.
  • All dates in UTC, shown in the time zone of the site.
  • Starting history on activation in background batches: every product gets its current price as the starting point. For a scheduled sale that has already started, the regular price is written as the price before the sale start. A tool and wp bwom backfill run it again at any time.

Correct legal logic

  • The reference period is the 30 days (or more) before the price reduction was introduced, not before today.
  • Progressive reductions: during an uninterrupted sale whose price only goes down, the period ends at the first step.
  • A sale price raised during a sale starts a new reduction, so the earlier lower price is shown.
  • Products offered for less than 30 days use the shorter period.
  • Periods when the product could not be bought (unpublished or out of stock) are left out; a product back in stock uses the last price at which it was offered.
  • A product introduced directly on sale has no earlier price; choose what to show (current price, regular price or nothing).
  • Settings apply at once to the whole stored history; no product has to be saved again.

Display

  • Product page: below the price or at five other places of the classic template, or at a custom action hook. In block themes the message follows the Product Price block.
  • Variable products: the message switches with the selected variation, in the classic form and in the add to cart blocks. Before a selection, the cheapest discounted variation or nothing.
  • Product lists (shop, categories, related products, product collection blocks), optional.
  • Cart, optional: classic cart and block cart (through the Store API).
  • The “Omnibus lowest price” block and the [bwom_lowest_price] shortcode for any place, with an optional product id and custom text.
  • Show only during a discount (as the directive requires) or always.
  • Text with placeholders: {price}, {days}, {date}, {reduction_date}, {current_price}, {regular_price}, {discount}, {history_days}. Translatable with WPML and Polylang.
  • Optional: use the lowest price of the reference period as the crossed-out price instead of the regular price.
  • Exclusions per product and per category.
  • A few lines of CSS that respect the theme, or none at all.
  • Prices shown with the tax display setting of the shop.
  • WooCommerce Multilingual & Multicurrency (WCML, with or without WPML) supported out of the box: prices set manually per currency get their own history, prices from exchange rates are converted with the current WCML rate, and the message text is translatable with WPML String Translation.

Admin

  • Omnibus price history box on the product edit screen: summary, a chart of the price over time (inline SVG, no external library) and the latest changes of the product and each variation.
  • Omnibus column in the product list with the lowest price and the start of the discount.
  • Products > Omnibus: price history of the whole store with filters, product search by id or SKU, settings, tools, diagnostics and an About tab.
  • CSV export of the whole history or of one product.
  • Retention setting that never removes rows needed by a running discount.
  • Diagnostics: table, history coverage, products on sale without a known start, background jobs, the WooCommerce sale job, tax and currency settings.

Performance

  • The lowest price is cached in the product meta, which WordPress loads together with the products, and cleared with every price change. Product lists are calculated with a single history query, so there are no N+1 queries in shop loops.

For developers and add-ons

  • bwom_get_lowest_price( $product ) returns the lowest price for any channel.
  • A channel registry (bwom/register_channels, bwom/channels) for add-ons such as a Google Merchant Center feed attribute, and the actions bwom/price_recorded and bwom/lowest_price_invalidated.
  • Filters for the recorded state, the currencies, the source, the calculation options and result, the message and its placeholders, the display decision and every admin screen.
  • Store API data (extensions.bwom on products and cart items), a read-only bwom_lowest_price field in the WooCommerce REST API, and REST routes under bwom/v1.
  • WP-CLI: wp bwom backfill [--all] [--background], wp bwom history <id>, wp bwom lowest <id>, wp bwom record <id>, wp bwom sync, wp bwom prune, wp bwom export [--file=<file>], wp bwom diagnose.
  • All front-end and admin views are templates a theme can override.

Documentation and support: https://beziworld.eu/projekty/lowest-price-history

Privacy

The plugin stores product prices and dates. For each change it stores the id of the shop staff member who made it; the WordPress personal data exporter and eraser cover these entries. No data of customers or visitors is collected, and the plugin makes no requests to external services.

Installation

  1. Install and activate WooCommerce.
  2. Upload the plugin folder to /wp-content/plugins/ or install it from the Plugins screen, then activate it.
  3. The starting history runs in the background. Check its progress in Products > Omnibus > Tools.
  4. Adjust the texts and the position in Products > Omnibus > Settings.

FAQ

Which price is shown as the lowest price?

The lowest price at which the product was offered during the 30 days before the current price reduction was introduced. The period is counted back from the start of the reduction, not from today, so a reduction that has lasted two weeks still refers to the 30 days before it started.

How are progressive reductions handled?

When a sale price is lowered step by step during one uninterrupted campaign, the period ends where the first step started, so the reference stays the price before the campaign. You can switch this off to treat every step as a new reduction.

What about new products?

For a product offered for less than 30 days, the shorter period since it was first offered is used. A product that was introduced directly on sale has no earlier price; you choose whether to show the current price, the regular price or no message.

What about products that were out of stock?

Periods when the product could not be bought (unpublished, a disabled variation or out of stock) are not counted, because no customer could buy at that price. When the product was not available at all during the period, the last price at which it was offered is used. You can switch this off.

I installed the plugin while a sale was already running. What is shown?

When the sale has a start date (“Sale price dates from”), the starting history writes the regular price as the price before the sale, so the correct reference is shown at once. Without a start date no earlier price is known and the fallback from the settings is shown; the diagnostics list these products.

Is this legal advice?

No. The plugin implements a common interpretation of Article 6a of Directive 98/6/EC as amended by Directive (EU) 2019/2161 and the European Commission guidance (2021/C 526/02), and national laws may add rules (for example for perishable goods or new products). It does not replace legal advice; check the requirements of your country and your offers with a lawyer.

Does it work with block themes and the block cart?

Yes. The message follows the Product Price block on product pages and in product collections, the “Omnibus lowest price” block can be placed anywhere, and the block cart shows the message through the Store API.

Does it work with WPML and WooCommerce Multilingual & Multicurrency?

Yes, automatically when the multi-currency mode of WCML is on (WCML also works without WPML). Products with prices set manually for a currency get a separate history in that currency, including their own sale dates. Products whose prices are calculated from exchange rates use the history in the store currency converted with the current WCML rate, the same way WCML converts the current price. With WPML, custom message texts are translated in String Translation.

Does it work with other multi-currency plugins?

The filters bwom/currencies and bwom/price_state keep a separate history per currency for plugins with fixed prices per currency, and bwom/convert_price converts the stored price into the visitor currency.

Does it slow down my shop?

No. Results are cached in the product meta and loaded together with the products. Product lists are calculated with one query for the whole page.

Is it compatible with HPOS?

Yes. The plugin works with products only and declares compatibility with High-Performance Order Storage and the cart and checkout blocks.

What happens when I delete the plugin?

The history is kept by default, because it may serve as evidence of correct price information. Switch off “Keep the price history and settings” in the settings to remove everything on deletion.

Screenshots

Changelog

1.0.1

  • Polish and German translations included with the plugin.
  • More space between the price history table and the links below it in the product editor.

1.0.0

  • First release.