Free & Open Source v1.0.0 Magento 2.4.x, PHP 8.1+

EU Base Price (Grundpreis) for Magento 2

Per-unit reference price display — legally compliant with German PAngV and EU Price Indication Directive. Shows price per kg, litre, metre on all surfaces.

View on GitHub composer require magendoo/module-base-price

Features

Full Storefront Coverage

Base price appears on product detail pages, category listings, search results, and shopping cart. Customers see the per-unit price everywhere they see a product price.

9 SI Units Pre-installed

Ships with kilogram, gram, litre, millilitre, metre, centimetre, square metre, piece, and pair. Add custom units via admin or API for industry-specific needs.

EU Legal Compliance

Meets German PAngV (Preisangabenverordnung) and EU Directive 98/6/EC requirements. Correct reference quantity formatting ensures your store passes legal review.

Configurable Templates

Customize the base price display format with placeholders for price, unit, and reference quantity. Match your store's design without touching template files.

REST API + Calculator

Full CRUD for units, per-product base price management, and a calculator endpoint that computes the reference price from product price, amount, and unit.

Per-Product Overrides

Set product amount, unit, and reference quantity per product. Override the calculated base price with a manual value when needed for promotional pricing.

Use Cases

  • German/EU stores requiring Grundpreis
  • Grocery and food ecommerce
  • Cosmetics and personal care
  • Hardware and textiles
  • Multi-pack products

Installation

Install via Composer

composer require magendoo/module-base-price
bin/magento module:enable Magendoo_BasePrice
bin/magento setup:upgrade
bin/magento setup:di:compile
bin/magento cache:flush

Post-Install Configuration

  1. Go to Stores → Configuration → Magendoo → Base Price
  2. Enable the module and select which surfaces display the base price
  3. Configure the display template (e.g., ({price} / {reference_quantity} {unit}))
  4. Review pre-installed units under Catalog → Base Price → Units
  5. Edit any product and fill in the Base Price tab: amount, unit, and reference quantity

REST API

MethodEndpointDescription
GET/V1/baseprice/unitsList all base price units
POST/V1/baseprice/unitsCreate a new unit
GET/V1/baseprice/units/:idGet unit by ID
PUT/V1/baseprice/units/:idUpdate a unit
DELETE/V1/baseprice/units/:idDelete a unit
GET/V1/baseprice/products/:skuGet base price data for a product
PUT/V1/baseprice/products/:skuSet base price data for a product
DELETE/V1/baseprice/products/:skuRemove base price from a product
POST/V1/baseprice/calculatorCalculate reference price from price, amount, and unit

Configuration

SectionConfig PathDescriptionDefault
Generalbaseprice/general/enabledEnable/disable the moduleYes
Generalbaseprice/general/templateDisplay format template({price} / {reference_quantity} {unit})
Generalbaseprice/general/css_classCSS class for the base price wrapperbase-price
Product Pagebaseprice/product/enabledShow base price on product detail pageYes
Product Pagebaseprice/product/positionPosition relative to main priceAfter price
Category / Searchbaseprice/listing/enabledShow base price in category and search listingsYes
Category / Searchbaseprice/listing/positionPosition in listing price blockAfter price
Cartbaseprice/cart/enabledShow base price in shopping cartYes
Cartbaseprice/cart/show_in_minicartShow base price in mini cartNo

Need help with installation or customization?

Every module is built for production, but every store is different. If you need integration, customization, or enterprise support — let's talk.

Get in Touch GitHub
22+ Years in Commerce Engineering
50+ Enterprise Magento Projects
EU Based in Europe, Serving Europe
OSS Open Source Contributor
Get a Proposal • 24h response Call