Margin Calculator — Cost, Price, Margin, Markup
Solve cost, price, margin and markup from any two, with fees, shipping and tax
Runs in your browser · nothing is uploaded
Enter it without sales tax or VAT; input tax is assumed to be reclaimed.
A percentage taken off the selling price, such as a marketplace or card fee.
Per-unit postage and packing paid by you.
Result
Enter any two values and the rest is worked out right away.
Margin and markup are not the same thing
For the same profit, margin divides by revenue and markup divides by cost, so markup is always the bigger number when there is a profit. A cost of 100 with a 25% markup sells at 125, which is only a 20% margin. Pricing for a "25% margin" instead gives 133.33, so never mix the two terms.
For estimates only. Cost is treated as tax-free, the fee is charged on the selling price, and coupons, ad spend and returns are not included.
What it is
Pricing questions come in two flavours: “What do I keep if I sell at this price?” and “What price leaves me the profit I want?” This calculator answers both. Pick the two values you know from cost, selling price, margin and markup, and it fills in the other two instantly. It works for online shops, restaurant menus, wholesale quotes or freelance rates, anything where a cost becomes a price. Add a fee rate, shipping you pay and an optional tax rate to see the true profit per unit. Everything is calculated in your browser and nothing you type is sent anywhere.
How to use
- Choose the pair you know: cost + price, cost + margin, cost + markup, or price + margin.
- Enter the two numbers. Cost should exclude sales tax or VAT.
- Add a marketplace or card fee rate and the shipping cost you cover, if any.
- Set the tax rate (leave 0 if none) and whether the selling price includes tax.
- Read the result: price, net revenue, fee, profit per unit, margin and markup, plus the formulas filled in with your numbers.
How it works
- Profit = net revenue − cost − fee − shipping. Net revenue is the price minus tax when the price includes tax.
- Margin = profit ÷ net revenue × 100. Markup = profit ÷ cost × 100.
- Solving a price for a target margin uses price = (cost + shipping) ÷ (net share × (1 − margin) − fee rate). This is the same idea as the common seller formula, supplier price ÷ (1 − (fee + target margin)), extended for tax.
- Rounding: the price is rounded to the smallest currency unit (cents) and every other figure is recomputed from it, so the table always adds up.
- If the fee rate is so high that the target margin cannot be reached, the calculator explains why instead of showing a wrong price.
Examples
| Situation | Input | Result |
|---|---|---|
| Cost 70, 30% margin | Cost + margin | Price 100, profit 30 |
| Cost 100, 25% markup | Cost + markup | Price 125, margin 20% |
| Price 100, 30% margin | Price + margin | Cost 70 |
| Cost 40, price 50 | Cost + price | Margin 20%, markup 25% |
| Cost 19.99, 40% margin | Cost + margin | Price 33.32 |
For estimates only. Check marketplace and tax rules for your own accounts.
FAQ
What is the difference between margin and markup?
Both describe the same profit, but they divide it by different numbers. Margin divides profit by the selling price, markup divides it by the cost. A cost of 100 sold at 125 makes 25 profit, which is a 20% margin and a 25% markup. Markup is always the larger figure when you make a profit, so a 25% markup and a 25% margin lead to different prices.
How do I price a product for a target margin?
With no fees or tax, price = cost ÷ (1 − margin). A cost of 70 and a 30% margin gives 70 ÷ 0.7 = 100. With a fee rate, shipping and tax in play the formula changes, so pick "Cost + margin" and let the calculator solve it, then read the fee and tax lines to check the result.
How is tax handled?
Leave the tax rate at 0 if you do not collect sales tax or VAT. Otherwise enter the rate and say whether your selling price already includes it. When it does, the tax is split out and margin is measured on the net revenue, because the tax is owed to the authorities rather than kept. Enter your cost without tax, assuming you reclaim input tax.
Which amount does the fee apply to?
The fee rate is multiplied by the selling price the customer pays. Marketplaces differ on whether shipping or tax is part of the fee base, so adjust the rate to match your statement if needed.
Are coupons, ads and returns included?
Not as separate fields. Lower the selling price for a coupon, and add ad spend per unit to the shipping field to get the same effect. Returns are not modelled, so keep a safety buffer in your margin.