Everyday Calculator Kit
Seller & business · EDITORIAL GUIDE

How to calculate profit margin, with examples

Profit margin tells you how much of every sale you keep. The formula fits on one line, but it's easy to mix up with markup. Here's how to calculate it, how to work backwards to a price, and a table to convert between the two.

By the Everyday Calculator Kit Editorial Team · Published · Updated · 2 min read

The formula

Profit margin = (price − cost) ÷ price × 100. If you sell a product for $50 and it costs you $30, the profit is $20 and the margin is 20 ÷ 50 = 40%. In other words, 40 cents of every dollar you take is profit.

The cost here is the full cost of the item: materials, making, packaging and any per-sale fees. If you only count materials, the margin looks better than it really is.

Margin vs markup

Markup uses the same profit but divides by the cost instead of the price. For the same $50 product, markup is 20 ÷ 30 = 66.7%. So a 66.7% markup and a 40% margin describe exactly the same sale.

This is where pricing mistakes come from. If you want a 40% margin but add 40% to your cost, you'll charge $42, and your real margin will be only 28.6%. The profit margin calculator shows both numbers side by side.

Markup and margin equivalents

Markup and margin equivalents
MarkupMarginPrice for a $10 cost
25%20%$12.50
50%33.3%$15.00
66.7%40%$16.67
100%50%$20.00
150%60%$25.00
200%66.7%$30.00

On a small screen, scroll the table sideways if needed.

Working backwards: price from a target margin

To find the price that gives a certain margin, divide the cost by (1 − margin). For a $30 cost and a 40% margin, that's 30 ÷ 0.6 = $50. For a 50% margin, it's 30 ÷ 0.5 = $60.

If a marketplace takes a percentage of the sale, include that too: price = cost ÷ (1 − margin − fee rate). Our selling price guide works through it, and the product pricing calculator does it for you.

Gross margin vs net margin

Gross margin uses only the direct cost of each product. Net margin takes off everything else too: rent, software, advertising, wages and tax. A shop can have a healthy 60% gross margin and still make a loss once those are paid.

Both are useful. Gross margin tells you whether each product is priced well. Net margin tells you whether the business as a whole is profitable. Our guide to gross and net profit has a worked example.

What's a good margin?

It depends heavily on the industry. Groceries run on thin margins with high volume; handmade goods, software and services often need much higher margins because volume is low and time is a big cost.

Rather than chasing a number, check two things: does the margin cover your overheads at the volume you actually sell, and is the price still competitive? The break-even calculator answers the first question.

Quick answers

Is a 50% markup the same as a 50% margin?

No. A 50% markup gives a 33.3% margin. For a 50% margin, you need a 100% markup.

How do I calculate margin in Excel?

Use =(B2-C2)/B2, where B2 is the price and C2 the cost, and format the cell as a percentage.

Can margin be more than 100%?

No. Margin can't reach 100%, because that would mean the item cost nothing. Markup can be any size.

Also useful: Product Pricing Calculator