Margin & Markup Calculator
Margin and markup both measure profitability, but they are calculated differently and are easy to confuse. Enter your cost and selling price to instantly see gross margin percentage, markup percentage, and profit amount — all updating live. Use the "Solve for price" mode to find the selling price that hits a target margin.
How It Works
Margin and markup are two of the most important concepts in pricing and financial analysis. They both express profit as a percentage, but the denominator is different — and that difference matters enormously in practice.
Gross Profit Margin is profit expressed as a percentage of the selling price (revenue):
Margin % = (Selling Price − Cost) ÷ Selling Price × 100
Markup is profit expressed as a percentage of the cost:
Markup % = (Selling Price − Cost) ÷ Cost × 100
Profit Amount = Selling Price − Cost
Worked example: Cost = $60, Selling Price = $100.
Profit = $100 − $60 = $40
Margin = $40 ÷ $100 × 100 = 40%
Markup = $40 ÷ $60 × 100 = 66.67%
Notice how a 66.67% markup translates to only a 40% margin. Confusing the two is a common and costly pricing mistake. If you tell a supplier you need a 40% margin and they apply a 40% markup instead, they will price the item at $84 instead of $100, and your actual margin will be only 28.6%.
Solving for price from cost and target margin:
Sometimes you know your cost and the margin percentage you need to hit. Rearranging the margin formula:
Selling Price = Cost ÷ (1 − Margin % ÷ 100)
Example: Cost = $60, target margin = 40%. Price = $60 ÷ (1 − 0.40) = $60 ÷ 0.60 = $100.
The relationship between margin and markup:
Markup % = Margin % ÷ (1 − Margin % ÷ 100)
Margin % = Markup % ÷ (1 + Markup % ÷ 100)
These formulas allow you to convert between the two measures. A 50% markup equals a 33.33% margin. A 100% markup (keystone pricing, common in retail) equals a 50% margin.
Frequently Asked Questions
What is the difference between margin and markup?
Margin divides profit by the selling price; markup divides profit by the cost. A product bought for $60 and sold for $100 has a $40 profit, a 40% margin (40/100), and a 66.67% markup (40/60). Always clarify which measure you are using when discussing pricing with others.
What is a good profit margin?
It depends heavily on the industry. Grocery retail often operates on 2–5% net margin. Software can exceed 70%. A typical small business gross margin target is 30–50%. Compare your margin against industry benchmarks rather than a universal target.
What is keystone pricing?
Keystone pricing means marking up the wholesale cost by 100%, resulting in a retail price exactly double the cost. This equals a 50% gross margin. It is a traditional rule of thumb in retail but may not be appropriate for all product categories.
Can margin exceed 100%?
No. Margin is bounded between 0% and 100% because profit cannot exceed the selling price. Markup, however, can exceed 100% — a product costing $1 and selling for $3 has a 200% markup but only a 66.67% margin.
How do I use the solve-for-price mode?
Switch to "Solve for price", enter your cost and the gross margin percentage you need to achieve. The calculator uses the formula Price = Cost ÷ (1 − Margin/100) to find the minimum selling price required. This is useful for setting prices that meet financial targets.