Like ToolFern? Prefer us as your source on Google →

Profit Margin Calculator

Enter what an item costs you and what you sell it for, and this calculator returns three numbers at once:profit in cash, profit margin as a share of the sale price, andmarkup as a share of the cost. Switch to Target margin to run the sum backwards, giving it the margin you want plus either the cost or the price so it solves for the side you are missing. A multi-item table underneath tracks several products at once and blends them into one weighted margin. The arithmetic runs in JavaScript on this page, so the figures you type are not sent to a server.

-
Profit
-
Profit margin %
-
Markup %

Profit = price - cost · Margin % = profit ÷ price · Markup % = profit ÷ cost. Margin needs a sale price above zero, markup needs a cost above zero. Everything is worked out in your browser. This is a general profit estimate, not financial advice.


Multi-item margin table

Add a few cost/sale price pairs, for example every SKU in a product line, and see each item's own margin plus a blended average margin for the whole list.

How to use this margin calculator

The tool has two modes, switched by the chips above the inputs.

  1. Margin and markup, the default. Enter cost (materials, wholesale price, or unit cost) and sale price, then read profit, profit margin % and markup %. Both boxes need a value before any result appears, and the figures refresh on every keystroke.
  2. Target margin, the reverse calculation. Pick whether to solve for sale price or cost using the chips in that section, enter your target margin plus the value you already know, and the tool fills in the missing one along with the resulting profit and markup.

Results are printed without a currency symbol, to two decimal places at most, so the same numbers work whether you sell in pounds, dollars, euros or rupees. Just keep the cost and the price in the same currency.

Margin and markup are not the same number

Profit is the easy part: profit = price - cost. The two percentages disagree because they divide that profit by different things. Margin % = profit ÷ price × 100 measures profit against the sale price, so it answers "how much of each sale do I keep?".Markup % = profit ÷ cost × 100 measures the same profit against the cost, so it answers "how much did I add on top?". Since the sale price is bigger than the cost on anything profitable, dividing by the price always hands you the smaller figure, which is why margin sits below markup on every profitable item you will ever put a ticket on. Retailers who simply double the wholesale price call it keystone pricing. That one move is a 100% markup and a 50% margin at once.

Mixing the two up is the classic pricing error, and it is expensive. A supplier quoting "50% markup" is really describing a 33.3% margin, so a manager who hears 50% and builds a budget on it comes up short by a sixth of the revenue they were counting on.

Worked example

Say an item costs you 40 and you sell it for 100.

Profit is 100 - 40 = 60. The margin is 60 ÷ 100 × 100 = 60%, so 60p in every pound you take is profit. The markup is 60 ÷ 40 × 100 = 150%, because you priced the item at 150% above what it cost you. Same item, same 60 of profit, two percentages that are nowhere near each other.

Which price should you enter? The VAT trap

If you are VAT-registered, the price on your shelf edge is not the price this calculator wants.

VAT collected on a sale is never yours. You hold it and hand it to HMRC, so it has no business sitting in the numerator or the denominator of a margin. Feed the calculator the net figure instead. HMRC calls the conversion the VAT fraction, and works it out as the rate of tax divided by 100 plus the rate of tax, which at the 20% standard rate gives 20/120, or exactly one sixth (VAT Notice 700, section 7.3.1).

Run the earlier example again with VAT in it. A ticket price of 100 including 20% VAT contains 100 × 1/6 = 16.67 of tax, leaving 83.33 that is actually yours. Against a 40 cost that is 43.33 of profit, a 52.00% margin and a 108.33% markup. The naive version claimed 60% and 150%. Eight points of margin vanished, and forty points of markup with it, purely because the wrong price went in the box.

Your cost usually needs the same treatment. A registered business reclaims input VAT on what it buys, so use the ex-VAT purchase price rather than the invoice total, otherwise you have deflated the margin from the other end.

The other quiet margin eaters

Card fees come out of gross margin before you see a penny of it. Inside the EU, Regulation (EU) 2015/751 caps interchange at 0.2% of the transaction for consumer debit cards and 0.3% for consumer credit (EUR-Lex, Article 3 and 4), but interchange is only the slice that reaches the card issuer. Scheme fees and your processor's own mark-up sit on top, which is why a typical high street card rate lands well above those caps.

Marketplace commission is heavier still, and it is usually charged on the full amount the buyer paid, shipping included, not on the item price alone. Add commission, packaging and postage to the cost box if you want the margin the business actually earns rather than the one the price tag suggests.

Solving for cost or price at a target margin

Pricing usually runs the other way round. You know the margin the business needs, you know one of the two figures, and the job is to work out the one you are missing before anyone prints a price list.

Solve for sale price when you know the cost:price = cost ÷ (1 - margin ÷ 100). A cost of 40 at a 60% target margin needs a price of 40 ÷ 0.40 = 100. That is the worked example above, reversed.

Solve for cost when you know the price:cost = price × (1 - margin ÷ 100). A 200 sale price at a 30% target margin needs a cost of 200 × 0.70 = 140, leaving 60 of profit.

Watch the ceiling. A target of 100% or more has no finite answer for any positive cost, because margin only ever creeps toward 100% as the price runs off toward infinity, and the tool flags that case with an alert rather than printing a nonsense number. Markup has no ceiling at all. It will happily reach 4,000%.

The multi-item table averages differently on purpose

Add a name, cost and sale price for each product and the table shows every item's own margin plus one blended figure for the whole list. That blend is total profit divided by total price, not the mean of the individual percentages, and the difference is not small.

Take two products. The first costs 40 and sells for 100, a 60% margin. The second costs 180 and sells for 200, a 10% margin. Average those two percentages and you get 35%. The table reports 26.67%, because 80 of profit against 300 of revenue is what the business actually banked. Averaging percentages silently treats a 200 sale and a 100 sale as equally important, and the cheap high-margin line flatters the whole product range. Weighting by price is the honest version, and it matches what your accounts will show at year end.

Frequently asked questions

What is the difference between margin and markup?

Both start from the same profit, price minus cost, but they divide it by different things. Margin is profit as a percentage of the sale price. Markup is profit as a percentage of the cost. A 50% markup is a 33.3% margin, and a 100% markup, the doubling that retailers call keystone pricing, works out at a 50% margin.

How do I calculate profit margin?

Subtract cost from sale price to get profit, divide that profit by the sale price, then multiply by 100. A 40 item sold for 100 has 60 of profit, so the margin is 60%.

How do I convert a markup percentage into a margin percentage?

Use margin = markup ÷ (100 + markup) × 100. A 25% markup is a 20% margin. A 50% markup is a 33.3% margin. A 150% markup is a 60% margin. Going back the other way, markup = margin ÷ (100 - margin) × 100.

Should I enter the price before or after VAT?

Before. VAT belongs to HMRC rather than to you, so leaving it in the box inflates the sale price and the apparent margin along with it. At the 20% standard rate one sixth of a VAT-inclusive price is tax, which turns a 100 ticket price into 83.33 of real revenue, and a registered business should strip VAT out of the cost side too because it reclaims that VAT anyway.

How do I find the price or cost needed to hit a target margin?

Switch to Target margin mode, choose whether to solve for sale price or cost, then enter your target margin percentage plus the value you already know. To solve for price: price = cost ÷ (1 - margin ÷ 100). To solve for cost: cost = price × (1 - margin ÷ 100). A cost of 40 at a 60% target margin needs a sale price of 100.

Why is the table's average margin different from averaging each item's margin?

It blends by value, dividing total profit by total price, so a big sale counts for more than a small one. Averaging the percentages instead would treat a 200 order and a 20 order as equals. Two items at 60% and 10% average to 35% that way, but blend to 26.67% by value, and only the second number matches the accounts.

Found this useful? Share it