Profit margin calculator
This profit margin calculator lets you calculate profit margin and markup, the selling price for a desired margin, or the maximum cost price you can still afford to pay — three related pricing questions in one tool.
1 Calculate profit margin and markup
2 Calculate selling price
3 Calculate maximum cost price
How to use this profit margin calculator
- Already know your cost and selling price? Use card 1 to calculate profit margin and calculate markup at once — they’re always different numbers for the same sale.
- Setting a price from scratch? Use card 2: enter your cost and target margin to calculate selling price.
- Negotiating with a supplier? Use card 3 to work backward from a fixed selling price and find the most you can pay and still hit your margin target.
What’s the difference between margin and markup?
Margin vs markup trips up more pricing decisions than almost any other confusion in small business finance. Profit margin expresses your profit as a percentage of the selling price. Markup expresses that same profit as a percentage of the cost price. This is a common source of confusion: with a cost price of $20 and a selling price of $35, the profit margin (15 ÷ 35) is 42.9%, while the markup (15 ÷ 20) is 75% — the same dollar profit, but a very different percentage, depending on what you base it on. The Corporate Finance Institute’s explainer on markup covers this same distinction in more depth if you want the accounting background.
| Term | Formula |
|---|---|
| Profit margin | (selling price − cost price) ÷ selling price × 100 |
| Markup | (selling price − cost price) ÷ cost price × 100 |
Worked examples
All figures below use the exact math this profit margin calculator runs in your browser.
Card 1: cost $20, selling price $35 (the defaults)
Profit: $15.00. Margin: 42.9%. Markup: 75.0%.
Card 2: cost $20, target margin 40% (the defaults)
Required selling price: $33.33 (profit $13.33) — not $28, which is what a naive “cost + 40%” markup calculation would give you.
Card 3: selling price $35, target margin 40% (the defaults)
Maximum cost price: $21.00 (profit $14.00).
Calculating selling price for a desired margin
If you want to achieve a specific profit margin, you don’t calculate the required selling price by simply adding the margin percentage to the cost price — that gives you a markup, not a margin. Instead, divide the cost price by (1 minus the desired margin). Card 2 of the profit margin calculator does exactly this.
Converting between margin and markup
You can switch between the two percentages without knowing the prices: margin = markup ÷ (100 + markup) × 100, and markup = margin ÷ (100 − margin) × 100. A 40% margin therefore needs a 66.7% markup, and a 75% markup gives a 42.9% margin. The profit margin calculator shows this matching markup next to every result, so you can check which figure a supplier is quoting. If you prefer to start from cost, the markup calculator works the other way round.
Common pricing mistakes a profit margin calculator helps you avoid
- Adding the margin percentage directly to cost. As the worked example above shows, “cost + 40%” produces a lower actual margin than 40% — always use the division formula, not a straight markup.
- Using margin and markup interchangeably in conversation. A “40% margin” and a “40% markup” describe two different selling prices; confirm which one a colleague or supplier means before quoting a number. Xero’s glossary entry on margin vs. markup is a useful quick reference if you need to double-check the distinction mid-conversation.
- Forgetting overhead beyond direct cost. The profit margin calculator uses the cost price you enter; if that figure excludes shipping, packaging, or platform fees, your real margin will be thinner than what’s shown.
Frequently asked questions
Why is my calculated selling price higher than cost price + margin percentage?
Because a margin of, say, 40% is calculated on the selling price, not on the cost price. Cost price + 40% is a markup calculation and results in a lower profit margin than the intended 40%.
Which percentage should I use: margin or markup?
That depends on the industry and convention. Retail often works with margin (percentage of the selling price), while some industries, such as wholesale, more often calculate with markup (percentage of the cost price).
Can margin be higher than 100%?
No. A profit margin can never exceed 100%, and it only reaches 100% when the cost price is $0, which is why the profit margin calculator asks for a target margin below 100%. Markup, on the other hand, can go above 100%.
Does this profit margin calculator work for services as well as physical products?
Yes — just treat your “cost price” as whatever it costs you to deliver an hour of service or a single job (labor, materials, overhead allocated per job), and the same margin, markup, and selling-price math applies without any changes.
What does the profit margin calculator not include?
It works on gross margin per unit: selling price minus the direct cost you enter. Rent, salaries and other fixed costs are not deducted. To see how many units you must sell to cover them, use the break-even calculator; to judge an investment in stock or equipment, use the ROI calculator.