Margin Calculator
This margin calculator solves the whole pricing picture from any two numbers you know. Enter a cost and a price, or a cost and the margin you want, or a price and a markup, and it fills in the rest: profit per unit, profit margin, markup, and the selling price. It even folds in quantity for total profit and a break-even count, so you go from "I want a 40% margin" straight to the price you should charge.
- Any two inputs
- Margin vs markup
- Profit per unit
- Total profit
- Break-even
Last updated July 21, 2026 Standard margin and markup formulas Reviewed by the Calcowa team
Fill in any two fields. The other two solve automatically as you type.
Profit as a share of price is your margin. Profit as a share of cost is your markup.
Markup to margin, side by side
The same profit looks bigger as a markup than as a margin, because markup is measured against the smaller cost and margin against the larger price. This table shows the exact pairs so you can sanity-check a price at a glance. Every row uses margin equals markup divided by one plus markup.
| Markup on cost | Equivalent margin |
|---|---|
| 25% | 20.0% |
| 50% | 33.3% |
| 75% | 42.9% |
| 100% | 50.0% |
| 150% | 60.0% |
| 200% | 66.7% |
| 300% | 75.0% |
| 400% | 80.0% |
How the margin calculator works
Everything starts from one number, the profit, which is simply the price minus the cost. Margin divides that profit by the price, markup divides it by the cost, and both are shown as a percentage. Because the four values are linked, knowing any two lets you solve the other two. The most useful direction is working backward from a target: to hit a margin you want, you divide the cost by one minus that margin to get the price.
Worked example
Say a product costs you $40 and you want a 60% margin. Divide $40 by one minus 0.60, which is 0.40, and you get a price of $100. Your profit is $100 minus $40, or $60 per unit. As a markup that is $60 divided by $40, which is 150%. Sell 100 of them and you make $6,000 in profit on $10,000 of revenue. If your fixed costs are $2,000, you divide by the $60 unit profit and break even at 34 units, so unit 35 onward is clear profit.
These figures are planning estimates. They ignore taxes, payment fees, discounts, and returns, so treat the result as a guide and confirm the numbers against your real books before setting a final price.
Frequently asked questions
They both measure profit, but against different bases, and mixing them up is the most common pricing mistake there is. Margin is your profit as a share of the selling price, so a $60 profit on a $100 sale is a 60% margin. Markup is that same profit as a share of the cost, so $60 profit on a $40 cost is a 150% markup. Same dollars, very different percentages. This margin calculator shows both at once from any two numbers you enter, so you never confuse the two again.
Subtract the cost from the price to get your profit, then divide that profit by the price and multiply by 100. So a product that costs $40 and sells for $100 makes $60 of profit, and $60 divided by $100 is 0.6, which is a 60% margin. The calculator does this the instant you type a cost and a price, and it also runs it in reverse: give it the margin you want and it tells you the price to charge.
Divide your cost by one minus the margin written as a decimal. For a 40% margin the divisor is 1 minus 0.40, which is 0.60, so a $30 item needs a price of $30 divided by 0.60, or $50. The trap is multiplying the cost by 1.40 instead, which actually gives you a 40% markup and only a 28.6% margin. Enter your cost and 40 in the margin field above and the tool sets the exact price for you.
Divide the markup by one plus the markup, both as decimals. A 150% markup is 1.5, so 1.5 divided by 2.5 is 0.6, a 60% margin. Going the other way, margin to markup, you divide the margin by one minus the margin: 0.6 divided by 0.4 is 1.5, or 150% markup. The reference table on this page lists the common pairs, and the calculator converts between them automatically whenever you fill in either one.
No, and that gap is where profit quietly leaks. A 50% markup on a $40 cost adds $20, giving a $60 price, but that $20 profit is only a 33.3% margin because it is measured against the higher selling price. To actually earn a 50% margin on that $40 item you would price it at $80, which is an 100% markup. Always confirm which base a percentage refers to before you set a price.
It depends heavily on the industry, so there is no single target. Grocery and retail often run on thin single-digit to low-double-digit margins and rely on volume, restaurants tend to sit in the low teens, while software and consulting can clear 50% or more. A useful move is to compare your margin to typical figures for your sector rather than to a generic number, and to track whether yours is trending up as you scale.
Break-even tells you how many units you must sell to cover your fixed costs, the expenses like rent and salaries that do not change with each sale. It divides your fixed costs by the profit you make on one unit. If each unit earns $60 and your fixed costs are $2,000, you break even at 34 units, since 33 would leave you slightly short. Every unit after that is pure profit, which is why a higher per-unit margin lowers the number you need to hit.
Related calculators
More pricing and money tools.
Price and profit from your cost.
Discount calculatorSale price and percent off.
Sales tax calculatorAdd or reverse tax on a price.
Pricing a product?
Set the margin above to find the price, then check the markup so nobody confuses the two.