Commercial Margin Calculator
Discount Calculator
Fill in any two fields — the other two are worked out for you.
VAT Calculator
Type into either box — the other is worked out at the selected rate.
How it works
Enter the cost price (what you pay for the product) and either the selling price (what you charge) or the target margin %, and the tool fills in the rest. From those two numbers everything else is computed live: gross profit, gross margin, markup percentage, discount-to-target-price, and the price after VAT.
Margin vs markup is the most common confusion in retail. They are not the same thing: • Markup = (sale − cost) / cost × 100. "How much I'm adding on top of cost." • Margin = (sale − cost) / sale × 100. "What fraction of the sale is profit."
A 50% markup equals a 33.3% margin. A 100% markup equals a 50% margin. Software-as-a-service with 90% gross margin has a 900% markup over server cost. Always say which one you mean: your accountant assumes margin, your supplier assumes markup, and the difference can be 30+ percentage points.
Discounts and VAT. Add a discount % to see the discounted selling price, and a VAT % to see the customer-facing price (most European invoicing wants the VAT-inclusive number alongside the net). The breakdown shows Subtotal → Discount → After Discount → VAT → Final price, so you can paste it into a quote without re-checking the arithmetic.
Multi-product table. The table at the bottom handles 5, 50 or 500 SKUs at once. Each row carries its own cost, sale, discount and VAT; the totals row sums net, gross, profit and tax across all rows. Save the configuration with one click and it goes to localStorage, so reopening the tool tomorrow finds your catalogue intact. Useful for building a price list, running a discount-day simulation, comparing margin uniformity across SKUs, or pulling a quick export for a B2B quote.
Pro tip: double-click any numeric cell in the table to open a built-in mini-calculator. Handy when the cost is a sum of components ("4.50 + 0.85 + 1.20 freight") that you want to evaluate inline without leaving the row.
Frequently Asked Questions
What is the difference between margin and markup?
- Margin is the share of the selling price that is profit; markup is the share of the cost you added on top. Same money, different denominator. A 50% markup over a €10 cost gives a €15 sale price, so margin = (15−10)/15 = 33.3%. A 100% markup gives a 50% margin. Memo: margin ≤ markup, always.
How do I calculate a target margin?
- Enter the cost price and the target margin %, and the tool computes the selling price you need to charge. The formula is sale = cost / (1 − margin). For a 30% margin on a €10 cost: sale = 10 / 0.7 = €14.29.
How do I calculate the selling price including VAT?
- Type your VAT rate into the VAT field. The breakdown then shows the net price (your margin calculation), the VAT amount (net × VAT%) and the final customer-facing price. For a €100 net at 22% VAT, customers pay €122.
Does the discount apply before or after VAT?
- Before. That is the convention in most European invoicing: subtotal, then discount, then VAT on the discounted amount. So a €100 item at 10% discount and 22% VAT becomes €100 − €10 = €90, plus €19.80 VAT = €109.80. The breakdown panel shows every step.
Can I save my product table?
- Yes. Click Save to push the current rows to localStorage; the saved set survives reloads and tab closures. Click Load to restore it. To move saves to another device, Export saves downloads them as a file you import there. In Chrome or Edge, Save to file in the Save All dialog keeps the tables synced with a .json file on your disk, saving every edit to it automatically.
Is the calculator accurate enough for accounting?
- Yes for analysis and quoting. The arithmetic is double-precision floating point rounded to 2 decimal places at display, the same precision your accounting software uses for line items. For a final invoice or end-of-year accounts, still confirm against your accounting software's own numbers: different rounding rules can produce 1-cent differences over many lines.
Is my data stored anywhere?
- No. Cost prices, sale prices and the rest of the catalogue never leave your browser. Save and Load use localStorage on your device only, and DevTools → Network confirms zero outbound requests during the entire workflow.
Margin ↔ markup conversion table
Quick reference for the most common margin/markup pairs. They are different denominators of the same profit, so the conversion is fixed.
| Markup % | Margin % | Sale price for €100 cost | Profit on €100 cost |
|---|---|---|---|
| 10% | 9.1% | €110 | €10 |
| 15% | 13.0% | €115 | €15 |
| 20% | 16.7% | €120 | €20 |
| 25% | 20.0% | €125 | €25 |
| 30% | 23.1% | €130 | €30 |
| 33.3% | 25.0% | €133.33 | €33.33 |
| 40% | 28.6% | €140 | €40 |
| 50% | 33.3% | €150 | €50 |
| 66.7% | 40.0% | €166.67 | €66.67 |
| 75% | 42.9% | €175 | €75 |
| 100% | 50.0% | €200 | €100 |
| 150% | 60.0% | €250 | €150 |
| 200% | 66.7% | €300 | €200 |
| 300% | 75.0% | €400 | €300 |
| 400% | 80.0% | €500 | €400 |
| 900% | 90.0% | €1,000 | €900 |
Conversion formula: margin = markup / (1 + markup). Inverse: markup = margin / (1 − margin). 100% markup = doubling the price; 50% margin = the customer pays twice the cost. The two never coincide: markup is always the larger number for the same profit.