Skip to content
CalcPilot
Salary calculator: gross to net pay for Canada, the US, the UK, France and Germany
Finance

Margin Calculator

Calculate gross margin and markup from cost and selling price.

Margin = (Price − Cost) ÷ Price · Markup = (Price − Cost) ÷ Cost

Try an example

Gross margin

40%

Markup66.67%
Profit per unit$40.00

About this calculator

What Is Profit Margin?

Profit margin tells you what share of your sales revenue is left as profit after the cost of making or buying the product. It is one of the first numbers any business owner, seller or freelancer should know, because it shows whether the prices you charge can actually sustain the business. Enter any two of cost, revenue (price), profit, margin or markup and this margin calculator fills in the rest.

The Key Formulas

  • Profit = Revenue − Cost
  • Margin (%) = Profit ÷ Revenue × 100
  • Markup (%) = Profit ÷ Cost × 100
  • Revenue from a target margin = Cost ÷ (1 − Margin)
  • Revenue from a target markup = Cost × (1 + Markup)

An item that costs $60 and sells for $100 earns a $40 profit — a 40% margin but a 66.7% markup.

Worked Example

A product costing $60 sold for $100 has a gross margin of 40% and a markup of 66.67% — the same $40 profit, expressed relative to two different bases.

Margin vs. Markup: A Common Mix-Up

Margin and markup both describe the same profit, but against different bases. Margin is measured against the selling price, so it can never reach 100%. Markup is measured against cost and can exceed 100%. A 50% markup is only a 33.3% margin. Confusing them is a common way to underprice a product — if you want a 40% margin, adding 40% to your cost gives you only about 28.6%.

Gross, Operating and Net Margin

  • Gross margin deducts only the direct cost of goods sold.
  • Operating margin also deducts operating expenses such as rent, wages and marketing.
  • Net margin is what is left after all expenses, interest and taxes.

Healthy margins vary a lot by industry: software can run above 70%, grocery retail is often in the low single digits.

Margin in Trading

In investing, "margin" has a different meaning: borrowing money from a broker to buy securities, where the broker requires you to put up a percentage of the purchase as collateral. Make sure you are using the right kind of margin for your question. For discounts and percentage changes in pricing, see the Discount Calculator and the Percentage Calculator.

Worked example

A product costing $60 sold for $100 has a gross margin of 40% and a markup of 66.67% — the same $40 profit expressed as a percentage of two different bases.

Frequently asked questions

What's the difference between margin and markup?

Margin is profit as a percentage of the selling price; markup is profit as a percentage of the cost. They describe the same dollar profit differently, and markup is always higher than margin for the same numbers (except at 0%).

Which one should I use to price a product?

Markup is usually easier to apply when pricing from cost ("add 50% markup to cost"), while margin is more useful for comparing profitability across products or against a target margin goal.

Does this account for all business costs?

No — this uses a single cost figure you provide. For a full profitability picture, make sure that cost includes everything relevant (materials, labor, overhead), not just the wholesale or unit cost.

More Finance calculators

Advertise on CalcPilot