What it does
The margin calculator works with a cost and a selling price:
- From price: from the cost and the selling price, the margin, the markup and the profit, for example a 40% margin and a 66.67% markup for a cost of 60 and a price of 100.
- From margin: from the cost and the margin you want, the selling price, for example 100.00 for a cost of 60 and a 40% margin.
- From markup: from the cost and a markup, the selling price, for example 75.00 for a cost of 60 and a 25% markup.
The result updates as you type.
How to use it
- Pick From price, From margin or From markup.
- Type the cost.
- Type the selling price, the margin or the markup, whichever the form shows.
- Select Copy result to put the figures on your clipboard.
The calculator remembers your choice and numbers on this device, so they’re there the next time you open the page.
How it’s calculated
With the cost c and the selling price P:
Margin = (P − c) ÷ P × 100
Markup = (P − c) ÷ c × 100
For a cost of 60 and a price of 100, Margin = (100 − 60) ÷ 100 × 100 = 40% and Markup = (100 − 60) ÷ 60 × 100 = 66.67%. From a margin m or a markup k in percent, the selling price is:
Price = c ÷ (1 − m ÷ 100)
Price = c × (1 + k ÷ 100)
The price is worked out exactly and rounded half up to whole cents once; the margin and markup shown are then worked out from that price. Percentages are rounded to 2 decimals, half away from zero, so a loss rounds the same way as the same profit.
Good to know
- The cost and the selling price can be from 0.01 to 1,000,000,000,000, and are rounded to whole cents.
- The margin can be from 0% to 99.99%, and the markup from 0% to 10,000%, in steps of 0.01.
- A price below cost is a loss, shown as a negative profit, margin and markup.
- On small amounts, rounding the price to whole cents can move the margin read back from it: a cost of 1.00 with a 0.01% margin gives a price of 1.00, a 0% margin.
- No currency is assumed: the amounts are in whatever currency you type.
Privacy
Everything is calculated in your browser, on your device. Nothing you type is uploaded. Only your choice and numbers are kept, in this browser’s storage, so the page can show them again.