Profit Margin Calculator

Last updated

This profit margin calculator works out your gross margin from revenue and cost, the selling price you need for a target margin, or the most you can spend for a target margin. Revenue of $200.00 with a cost of $150.00 is $50.00 of profit, a 25% margin. Markup shows beside it so you can compare the two.

Loading calculator…

How to use the profit margin calculator

  1. Choose whether you want your margin, the selling price for a target margin, or the maximum cost for a target margin.
  2. Enter the two numbers that mode asks for.
  3. Read the answer, with profit and markup shown beside it.

How profit margin is calculated

Margin from revenue and cost

Profit = Revenue − Cost
Margin % = Profit ÷ Revenue × 100

Selling price for a target margin

Price = Cost ÷ (1 − Margin % ÷ 100)

Maximum cost for a target margin

Cost = Revenue × (1 − Margin % ÷ 100)

Markup (shown for comparison)

Markup % = Profit ÷ Cost × 100

Profit Margin Calculator examples

Example 1: finding the margin

Revenue $200.00, cost $150.00. Profit = $50.00. Margin = $50.00 ÷ $200.00 = 25%. Markup = $50.00 ÷ $150.00 = 33.33%.

Example 2: the price for a 25% margin

Cost $75.00. Price = $75.00 ÷ (1 − 0.25) = $75.00 ÷ 0.75 = $100.00. Profit is $25.00.

Example 3: the maximum cost

You sell at $100.00 and want a 40% margin. Cost can be at most $100.00 × 0.6 = $60.00.

Margin on a $100 sale

How the cost of goods changes margin and markup on the same $100.00 of revenue.

Margin and markup for a $100 sale
CostProfitMarginMarkup
$90.00$10.0010%11.1%
$80.00$20.0020%25%
$70.00$30.0030%42.9%
$60.00$40.0040%66.7%
$50.00$50.0050%100%

Gross, operating and net profit margin

There are three margins, and each subtracts more. Take a business with $200,000.00 of revenue in a year.

  • Gross margin. Revenue minus the direct cost of what you sold. With $120,000.00 of cost of goods, gross profit is $80,000.00, a 40% gross margin. This is what the calculator above works out.
  • Operating margin. Gross profit minus running costs such as wages, rent and marketing. With $50,000.00 of those, operating profit is $30,000.00, a 15% operating margin.
  • Net margin. Operating profit minus interest, tax and anything else left. With $10,000.00 of those, net profit is $20,000.00, a 10% net margin.

For a whole business, enter total revenue and total cost: $50,000.00 of sales with $32,500.00 of cost is $17,500.00 of profit, a 35% margin. To estimate net margin with the calculator, put every cost you want counted into the cost field.

What is a good profit margin?

There is no single answer, because margins differ a great deal between industries. One public reference is the margin data compiled by Professor Aswath Damodaran at NYU Stern from US listed companies (data as of January 2026). A sample of sectors:

Gross and net margin by sector, US firms, January 2026
SectorFirmsGross marginNet margin
Software (system and application)30971.72%25.49%
Apparel3556.88%3.85%
Advertising5236.24%-0.30%
Retail (general)2333.18%5.61%
Restaurant and dining6432.24%9.37%
Retail (grocery and food)1526.31%1.32%
All US firms in the data set5,99437.76%9.74%

Software is far above grocery retail, and advertising, on average, had a slightly negative net margin in this data set. These are averages for large listed companies, so a small shop or a freelancer will sit differently. The most useful comparison is your own margin over time, and against businesses of your own type and size. Source: NYU Stern, Operating and Net Margins by Sector (US).

Margin or markup?

Margin divides profit by the selling price. Markup divides it by the cost. A 25% margin is a 33.33% markup, so a price built on a 25% markup earns less than 25% of each sale. The markup calculator converts between the two, and its table shows common pairs.

Three ways margin goes wrong

  • Counting list price, not what you got. An item that costs $60.00 and lists at $100.00 has a 40% margin. Sold at 20% off for $80.00, it has a 25% margin. Use the price you actually received, after discounts and returns.
  • Leaving out costs. Shipping in, packaging, payment fees and returns are part of what a sale really costs. Leave them out and the margin looks better than the business is.
  • Mixing up margin and markup. They are different percentages of the same profit, so quoting one as the other overstates or understates what you earn.

Profit Margin Calculator questions

What is profit margin?

Profit margin is the share of your revenue that is left as profit. Gross profit margin uses revenue minus the direct cost of what you sold. A 25% margin means you keep 25 cents of every dollar of sales, before overhead.

How do I calculate profit margin?

Subtract cost from revenue to get profit, divide by revenue, and multiply by 100. Revenue $200.00 and cost $150.00 give profit $50.00, and $50.00 ÷ $200.00 = 0.25, a 25% margin.

What is the difference between margin and markup?

Margin divides profit by revenue; markup divides profit by cost. The same $50.00 profit on $150.00 cost is a 25% margin but a 33.33% markup. The markup calculator works from cost.

What selling price gives me a 25% margin?

Take the cost and divide it by 1 minus the margin as a decimal. For a $75.00 cost: $75.00 ÷ 0.75 = $100.00. Adding 25% to the cost would give $93.75, which is only a 20% margin.

What is gross profit margin?

It is gross profit divided by revenue, where gross profit is revenue minus the direct cost of what you sold. Revenue $200,000.00 with cost of goods $120,000.00 gives gross profit $80,000.00 and a 40% gross margin.

How do I calculate net profit margin?

Subtract all costs, not just the cost of goods, then divide by revenue. In the example above, $200,000.00 of revenue less $120,000.00 cost of goods, $50,000.00 of operating costs and $10,000.00 of interest and tax leaves $20,000.00, a 10% net margin.

What is a good profit margin?

It depends heavily on the industry. The table above shows how different sectors look in one public data set: software sits far above grocery retail. Compare your own margin with your own past months and with businesses like yours, not with a single number.

Can profit margin be more than 100%?

No. A margin of 100% means zero cost, so it is the ceiling. Margin can be negative if costs are higher than revenue. Markup, by contrast, can be over 100%.

How do discounts affect margin?

They cut it faster than you might expect. An item that costs $60.00 and sells for $100.00 has a 40% margin. At 20% off it sells for $80.00, and the margin falls to 25%. Use the discount calculator to check a sale price first.

Is this gross margin or net margin?

Gross margin. It only subtracts the cost you enter. Net margin also subtracts overhead, salaries, advertising, interest and taxes, so it’s lower. Include the costs you care about in the cost field to get closer to a net figure.

Can the margin be negative?

Yes. If cost is higher than revenue you’re selling at a loss. $100.00 of cost sold for $80.00 is a -25% margin.

What this calculator doesn’t do

  • It calculates gross margin from the cost you enter. It doesn’t include overhead, tax, discounts, returns or fees unless you add them to the cost.
  • It works per sale or per unit. For a whole business, enter total revenue and total cost.
  • It doesn’t say what margin is good for your industry.
  • It isn’t tax or accounting advice.

Results are estimates for planning, not financial advice. The methodology page explains how every calculator here is built and checked.

More calculators