On a standard Magento product page the price always refers to one piece, whatever quantity the shopper enters. With this module the displayed price follows the quantity field: when a shopper enters 5, the product page shows the price for 5 pieces. Optionally, the price per piece stays visible as well, so shoppers see both the total and the unit price before adding the product to the cart.
Features
- The price on the product page, including prices of selected options, is multiplied by the quantity entered.
- Tier prices are taken into account, also for the variants of configurable products.
- Optional unit price shown next to the main price, labelled “Unit Price” and “per item”.
- Optional hint at the quantity field, for example “€9.99 / Item”, shown when more than one piece is selected. It also works with quantity dropdowns.
- Works with variant selection of configurable products and with personal prices from “Catalog Product Price Calculation”.
Configuration
Go to Stores > Configuration > Infrangible Solutions > Catalog Product Qty > Product View. “Show Unit Price” adds the unit price next to the price, “Show Unit Price Hint” adds the per-item hint at the quantity field. Both are off by default and can be set per website and store view.
Good to know
Pairs well with “Catalog Product Qty Steps”, which replaces the quantity field with a dropdown of fixed quantities. The module is built for the standard Magento frontend (Luma and Luma-based themes).
Installation
Install the module with Composer in your Magento root directory:
composer require infrangible/m2-catalog-product-qtyThen enable it and update the store as described in the installation guide. Composer installs the required modules listed on this page automatically.