SafeSale · Blog

Unit prices during a Shopify sale: what the per 100 g line shows

Shops that show a price per 100 g or per litre need that line to follow the sale. How it behaves when the price is rewritten and when a discount is used.

A coffee roaster in Hamburg sells the same beans in 250 g, 500 g and 1 kg bags. Under the price of each one there is a second, smaller line: 2.40 per 100 g, 2.20 per 100 g, 2.00 per 100 g. Shoppers use that line to decide which bag to buy, and in a lot of countries the shop is required to show it. Then the roaster runs 20% off for a week, and the question nobody asked during setup arrives: does the small line change too?

It depends on how the sale is built. SafeSale runs a sale in one of two ways, by rewriting prices or by creating an automatic discount, and the unit price behaves differently in each. This post goes through both, plus two pricing rules that do odd things to per-unit figures.

Where the unit price comes from

Shopify does not let you type a unit price. On the variant you tick the unit price option and enter two things: how much is in the pack (500 g) and the base measure you want to quote against (100 g). Shopify divides and shows the result. Change the price and the figure changes with it. Shopify's unit pricing page says the result is shown on product pages, collection pages, the cart and checkout of any Online Store 2.0 theme, and in the default order confirmation email.

So the unit price is not a separate number that a sale has to remember to update. It is a view of the variant price. Whatever changes the variant price moves it, and whatever does not change the variant price leaves it alone. That one fact explains everything below.

Price-rewrite mode: the line follows the sale

In price-rewrite mode SafeSale writes the sale price into the variant and puts the original price into compare-at, so the theme shows the old price struck through. Those are the only two fields it writes. The measurement and base measure are untouched.

Because the variant price is now the sale price, Shopify recalculates. The 500 g bag at 11.00 becomes 8.80, and the line under it goes from 2.20 to 1.76 per 100 g. That happens everywhere the unit price appears: the collection grid, the product page, the cart drawer, checkout, the confirmation email. There is nothing to switch on.

When the sale ends, SafeSale restores each variant from the snapshot it took before the first write. The price returns to 11.00, the compare-at returns to whatever it was (usually empty), and the unit line reads 2.20 again. If a restore is interrupted and retried, the unit price for each variant is right the moment its price is, because it is the same write.

Automatic-discount mode: the line stays where it was

In discount mode SafeSale creates one automatic discount and the variant prices are not changed at all. The product page shows the regular price, and the discount appears once the item is in the cart.

The unit price on product and collection pages comes from the variant, so it keeps showing the regular figure: 2.20 per 100 g, during a sale in which the shopper will pay the equivalent of 1.76. In the cart and at checkout the picture is better. Shopify's theme reference describes the unit price of a cart line as reflecting discounts applied to that line, so a theme that prints it there shows the discounted figure. Whether yours does is worth one look in a test cart.

For most stores that mismatch is cosmetic. For a store that shows unit prices because the law says so, a product page that advertises a sale while quoting a per-unit figure nobody will pay is not something to leave to chance. The practical rule: if unit prices matter in your market, run the sale in price-rewrite mode.

There is one unit price, not two

During a rewrite sale the product page shows two prices, the sale price and the struck-through original. It shows one unit price, for the sale price. Shopify's standard themes do not print a struck-through unit price next to the struck-through price.

That is usually what shoppers want, since the per-unit figure exists to compare what things cost now. If you sell in the EU, remember there are two separate rules in play. One says to show a unit price. The other, added by the Omnibus directive, says a price reduction has to be announced against the lowest price of the previous 30 days. SafeSale's compare-at is the price from just before the sale, which is your reference price only if you had not already lowered it in that window. We are a pricing tool, not a law firm; if you are unsure how either rule applies to you, ask someone who is.

Rounding to .99 and the unit line

SafeSale can round sale prices to end in .99 or .95, or to a whole amount, and it only ever rounds down so the discount is never smaller than you asked for. The unit price is calculated after that, from the rounded price.

Take 20% off a 500 g bag at 12.49. The exact result is 9.99, no rounding needed, and the unit line reads 2.00 per 100 g, because 1.998 is displayed to two decimals. Take 20% off 11.00 with .99 rounding and 8.80 becomes 7.99, so the line reads 1.60 where the exact discount would have given 1.76. Nothing is wrong, but if you have printed 1.76 on a shelf label or in a newsletter, the site now disagrees with it. Quote unit prices in marketing only after you have seen the preview.

Amount off and fixed price across pack sizes

Percentage sales keep the order of unit prices intact: if the big bag was the best value before, it is the best value during. The other two rule types do not promise that.

  • Amount off. 2.00 off every size is 33% off a 6.00 bag and 10% off a 20.00 bag. The 250 g bag drops from 2.40 to 1.60 per 100 g while the 1 kg bag drops from 2.00 to 1.80. For the week of the sale the small bag is the better deal, and a shopper who reads the small line will buy four of them instead of the kilo.
  • Fixed price. Setting every variant to 9.99 makes the 1 kg bag 1.00 per 100 g. SafeSale's hard cap blocks any variant whose discount would pass 90% by default, and anything over 50% asks for a typed confirmation, so the worst cases stop at the preview. A 50% cut on your largest size will still go through if you confirm it.

The fix for both is in the preview table. Every variant row can carry its own rule, so the 250 g bag can take 1.00 off while the kilo takes 4.00, or the sizes can each get their own fixed price. The preview lists the new price and the discount percentage per variant; divide by the pack size for the two or three products where the order matters, before you publish.

Markets and currencies

Shopify shows the same unit type in every market, so a product measured per 100 g is per 100 g everywhere. The amount is calculated from whatever price that market's shopper sees. In rewrite mode the sale price in your store currency is converted like any other price, and the unit line is derived from the converted amount. If a market has a fixed price set by hand for a product, that fixed price is what the shopper sees there, and its unit line follows it, not the sale. Our post on markets and currencies covers which prices a sale reaches.

A five-minute check before the sale

  1. Create the sale and stop at the preview. Find one product that has unit pricing and note the new price for each size.
  2. Divide each new price by its pack size. Check that the order of best value is the one you want.
  3. Schedule the sale to start on one product a few minutes from now, or run it on a test product.
  4. Open the product page, a collection page and the cart. In rewrite mode all three should show the new per-unit figure. In discount mode, look at what the product page says and decide if you can live with it.
  5. End the test sale and confirm the line is back to the regular figure.

Stores that sell by weight or volume tend to have few products and loyal customers who know the per-unit price by heart. They notice when the small line is wrong before they notice anything else. Rewrite mode keeps it right without any work from you, which is a good enough reason to pick it for this kind of catalog. The comparison of the two modes has the rest of the trade-offs.

Frequently asked questions

Does the unit price update when SafeSale puts a product on sale?

In price-rewrite mode, yes. Shopify calculates the unit price from the variant price and the measurement you entered on the product, so when SafeSale writes the sale price the per 100 g or per litre figure follows on product pages, collection pages, cart and checkout. SafeSale writes only the price and the compare-at price and never touches the measurement fields. When the sale ends and the price is restored, the unit price goes back with it.

Why does the unit price still show the full price during my automatic discount?

Because an automatic discount does not change the variant price. Product and collection pages read the unit price from the variant, so they keep showing the regular figure. The discount is applied in the cart and at checkout, where the line can show a unit price that reflects it, depending on the theme. If the per-unit figure has to be right on the product page, use price-rewrite mode.

Is there a struck-through unit price for the old price?

Not in Shopify's standard themes. The compare-at price is shown struck through, but only one unit price is displayed, the one for the current price. If your market expects the previous unit price too, that is a theme change, and worth checking with whoever advises you on price display rules.

Can an amount-off sale make the small pack cheaper per unit than the big one?

Yes. Taking the same amount off every size is a bigger percentage on the small pack. A 250 g bag at 6.00 and a 1 kg bag at 20.00 are 2.40 and 2.00 per 100 g; with 2.00 off each they become 1.60 and 1.80. The preview shows every variant's new price and discount percentage before anything is written, so you can catch it and give the sizes different rules.