Skip to content

Margin Calculator

An item that costs $120 and sells for $160 earns $40 profit: a 25% margin on the price and a 33.33% markup on the cost. Choose which two numbers you know to get the rest.

Margin is profit as a share of the price; markup is profit as a share of the cost. The same $40 profit on a $120 cost and a $160 price is a 25% margin and a 33.33% markup.

Gross margin

25%

Selling price
$160.00
Cost
$120.00
Profit
$40.00
Markup
33.33%
How it’s calculated
  1. Profit$160.00 − $120.00 = $40.00
  2. Margin$40.00 ÷ $160.00 = 25%
  3. Markup$40.00 ÷ $120.00 = 33.33%
Price for a target margin on a $120.00 cost
MarginMarkupPriceProfit
10%11.11%$133.33$13.33
20%25%$150.00$30.00
25%33.33%$160.00$40.00
30%42.86%$171.43$51.43
40%66.67%$200.00$80.00
50%100%$240.00$120.00
60%150%$300.00$180.00

Updates as you typeNo sign-upShare the link and your numbers travel with it

How to calculate margin and markup

Every pricing question uses three dollar amounts — the cost, the selling price and the profit between them — and two percentages:

  • Profit = price − cost
  • Gross margin = profit ÷ price
  • Markup = profit ÷ cost

With a $120 cost and a $160 price, the profit is $40, the margin is 40 ÷ 160 = 25%, and the markup is 40 ÷ 120 = 33.33%. Choose I know the to start from any pair — cost and margin, price and profit, and so on — and the calculator works out the rest, with each step shown.

Margin vs markup

The same profit is a smaller percentage of the price than of the cost, so a margin is always below the matching markup:

Margin Markup Price on a $100 cost
10% 11.11% $111.11
20% 25% $125.00
25% 33.33% $133.33
30% 42.86% $142.86
40% 66.67% $166.67
50% 100% $200.00
60% 150% $250.00

Mixing them up is the most common pricing error. Adding 30% to a $120 cost gives $156 — but that is only a 23.08% margin. To earn a 30% margin, divide the cost by 0.70 instead: $171.43. The table under the result lists the price for common target margins on your own cost.

Pricing for a target margin

To set a price from a margin goal, divide the cost by one minus the margin: price = cost ÷ (1 − margin). For a 40% margin on a $60 cost, $60 ÷ 0.60 = $100. To go from a markup, multiply: price = cost × (1 + markup). Retailers often quote margins, while wholesalers and contractors more often quote markups, so check which one a supplier or a client means before you agree on a number.

Gross margin, net margin and discounts

This calculator gives the gross margin on one item: price minus the cost of the goods. Net margin takes out every other expense — rent, wages, marketing, taxes — and is calculated on total revenue. A discount comes straight out of the margin: on a $160 item with a $120 cost, 10% off the price ($16) cuts the profit from $40 to $24, a 16.67% margin. To see sale prices after one or more discounts, use the percent off calculator; for other percentage questions, the percentage calculator; and to compare an hourly rate with a salary when pricing your own time, the hourly to salary calculator.

Frequently asked questions

How do you calculate profit margin?

Subtract the cost from the price to get the profit, then divide the profit by the price. $160 − $120 = $40, and $40 ÷ $160 = 25%.

What is the difference between margin and markup?

Both use the same profit. Margin divides it by the selling price; markup divides it by the cost. A $40 profit on a $120 cost and a $160 price is a 25% margin but a 33.33% markup.

How do I price something for a 30% margin?

Divide the cost by 1 minus the margin: $120 ÷ 0.70 = $171.43. Adding 30% to the cost gives only $156, which is a 23% margin.

How do I convert markup to margin?

Margin = markup ÷ (1 + markup). A 50% markup is a 33.33% margin, and a 100% markup — doubling the cost — is a 50% margin.

Can a margin be more than 100%?

No. Margin is a share of the price, so it stays under 100% unless the cost is zero. Markup has no upper limit: selling a $10 item for $50 is a 400% markup but an 80% margin.

Is gross margin the same as net margin?

No. Gross margin uses only the cost of the goods; net margin subtracts all expenses, such as rent, wages and taxes, before dividing by revenue. This calculator works out gross margin per item.