Profit Margin Calculator

Find your gross profit, margin percentage, and markup from cost and selling price.

Advertisement

How profit margin works

Profit margin measures what percentage of revenue remains as profit after subtracting the cost of goods. It is one of the most important metrics in business pricing.

Gross Profit = Revenue - Cost Profit Margin % = (Gross Profit / Revenue) x 100

Example 1 (retail): You sell a product for $80 and it costs $52. Profit = $28. Margin = ($28 / $80) x 100 = 35%.

Example 2 (finding the right price): Your product costs $45 and you want a 40% margin. Price = $45 / (1 - 0.40) = $45 / 0.60 = $75.00.

Margin vs. markup: a critical distinction

MetricFormulaBased On$45 cost, $75 price
Margin(Price - Cost) / PriceRevenue40%
Markup(Price - Cost) / CostCost66.7%

Typical profit margin benchmarks by industry

IndustryTypical Gross Margin
Software / SaaS60-80%
Consulting / services50-70%
Ecommerce (retail)20-50%
Restaurants60-70% gross (3-9% net)
Manufacturing25-40%
Grocery / supermarket20-30%
Construction15-25%
Automotive dealer10-20%

Margin is not the same as profit

Gross margin only accounts for the direct cost of what you sold. It does not include operating expenses like rent, salaries, or marketing. Net profit margin subtracts all expenses. A business can have a 60% gross margin and still lose money if overhead is high.

When to use the margin calculator

  • Setting the right selling price for a product to hit a target margin
  • Comparing profitability across different products in your inventory
  • Checking whether a discount still leaves enough margin to be profitable
  • Presenting gross margin to investors or in a business plan
  • Converting between margin and markup when talking to suppliers or buyers

Why margin matters more than markup

Small business owners and freelancers often set prices by intuition -- and discover too late that after costs, their margin is too thin to survive, let alone grow. The core problem is almost always the same: they used markup math when they needed margin math, or they included too few costs in their cost figure. Gross margin tells you what percentage of every dollar of revenue stays with you after paying for what you sold -- and it is the single most important pricing metric in any product or service business.

The markup and margin figures shown side by side in this calculator exist precisely because they are so frequently confused. A 50% markup feels like a 50% margin -- but it is actually a 33% margin. Understanding why closes the most common pricing gap in small business.

How to interpret your margin result: a step-by-step framework

  1. 1Include every direct cost in the cost field: Cost of goods should include materials, manufacturing or purchase cost, inbound shipping, packaging, payment processing fees (Stripe, PayPal, Square each take 2.9-3.5%), and platform fees (Etsy, Amazon, eBay commissions). Omitting any direct cost overstates your margin. A common mistake: forgetting that a 2.9% processing fee on a $100 sale reduces your net to $97.10 before you count any other cost.
  2. 2Enter the actual transaction price, not your list price: If you offer discounts, enter the discounted price the customer actually pays. A 20% promotional discount on a $100 product means the sale price is $80 -- and your margin is calculated on $80, not $100. Running promotions without checking post-discount margin is one of the most common ways small businesses accidentally sell at a loss.
  3. 3Read gross margin as a floor, not the whole picture: Gross margin accounts only for direct costs of the product or service -- it ignores rent, salaries, marketing, software, insurance, and all other overhead. Your net margin (what remains after everything) will be significantly lower. A business with 60% gross margin can still be losing money if overhead is high relative to revenue. Gross margin tells you whether the product itself is viable; net margin tells you whether the business is viable.
  4. 4Compare your margin to your industry benchmark: Margin varies dramatically by industry, and a number that looks thin in one context is healthy in another. Grocery and food retail typically runs 20-30% gross margin; software and SaaS runs 60-80%; professional services run 50-70%. If your margin is well below your industry benchmark, it signals either a pricing problem or a cost problem worth investigating.
  5. 5Use the markup to set prices; use the margin to report profitability: Markup is the more intuitive tool when calculating what to charge (add X% to cost). Margin is the standard for financial reporting, investor conversations, and benchmarking against industry data. Knowing which convention your audience expects prevents miscommunication -- especially when presenting financials to a bank, investor, or accountant.

Markup vs. margin: the key difference

These two calculations are related but not interchangeable. Using the wrong one when setting prices is a reliable path to undercharging.

Markup uses cost as the base

Markup % = (Profit / Cost) x 100. A product that costs $60 and sells for $100 has a markup of 66.7%. This is easy to calculate when you start from cost.

Margin uses revenue as the base

Margin % = (Profit / Revenue) x 100. The same product -- cost $60, sell for $100 -- has a margin of 40%. Lower percentage, same product, same profit in dollars.

To price for a target margin

Use: Selling Price = Cost / (1 - Target Margin). For a 40% margin on a $60 cost: $60 / 0.60 = $100. If you mistakenly apply 40% as a markup instead: $60 x 1.40 = $84. You would earn only a 28.6% margin -- significantly below your target.

3 common margin mistakes

1Confusing markup percentage with margin percentage: A 50% markup produces only a 33% margin. A 100% markup (doubling the cost) produces a 50% margin. If you add 40% to your cost thinking you will achieve a 40% margin, you actually earn 28.6%. Always use the margin formula -- or the "price for target margin" formula above -- when your goal is a specific gross margin.
2Omitting payment processing fees from cost: Stripe, PayPal, and Square each take 2.9-3.5% plus a flat fee per transaction. On a $200 sale, that is $5.80-$7 in processing cost before you account for anything else. At scale, this is a significant cost. Always include processing fees in your cost figure when calculating margin on e-commerce or card transactions.
3Using gross margin to evaluate overall business profitability: Gross margin only accounts for direct costs -- what it costs to make or buy what you sold. Rent, salaries, marketing spend, software subscriptions, and taxes all come after gross profit. A business with 60% gross margin can absolutely be losing money if its overhead structure consumes more than 60 cents of every revenue dollar. Use gross margin to evaluate product pricing, and net margin to evaluate the business.

What to do next

See how a promotional discount affects your margin with the Discount Calculator -- enter your discounted price to see margin at the promotional rate. Track revenue growth over time with the Percentage Change Calculator. For a deep dive into the difference between gross, operating, and net margin with industry benchmarks, read the guide on profit margin explained.

Advertisement

FAQ

Frequently asked questions

About this calculator

This profit margin calculator uses the standard gross margin formula: Margin = (Selling Price - Cost) / Selling Price x 100. Markup is calculated as (Selling Price - Cost) / Cost x 100, representing the percentage added over the cost base. These definitions align with standard accounting practice as outlined in GAAP (Generally Accepted Accounting Principles) guidance published by the Financial Accounting Standards Board (FASB).

Industry margin benchmarks referenced on this page are drawn from NYU Stern School of Business's annually updated margin dataset by industry sector, and from the Corporate Finance Institute's published margin guidelines. Retail margin norms reflect data from the National Retail Federation (NRF) annual industry report.

This tool is maintained by the MyPctCalculator editorial team. All calculations run locally in your browser; no input data is stored or transmitted.