Profit Margin Calculator
Margin, markup & profit from cost and price
Pricing a product? Enter your cost and selling price to see your profit, margin and markup at once. Add a target margin and this profit margin calculator works backwards to the price that actually hits it — the calculation most people get wrong by adding a percentage to cost instead of dividing by it.
Margin and markup measure different things
Margin is profit as a share of the selling price. Markup is the same profit as a share of the cost. The dollars are identical; only the denominator changes, and because price is always larger than cost, the margin percentage is always the smaller of the two.
Sell a $40 item for $100 and you make $60. Against the $100 price that is a 60% margin. Against the $40 cost it is a 150% markup. Same $60 either way. Used as a markup calculator, this tool gives you both at once so you never quote one and bank the other.
The classic error: adding 40% to a $40 cost gives $56, and $16 of profit on a $56 price is a 28.57% margin — not 40%. A real 40% margin needs a price of $66.67, which is a 66.7% markup. Price by adding a percentage and you will be short of your target on every single sale.
The markup and margin conversion table
Read it in either direction. The left pair answers "I add this much to cost — what margin does that leave?" The right pair answers "I need this margin — what do I charge?" Prices are shown for a $40 unit cost.
| Markup you add | Margin it leaves | Margin you want | Markup that needs | Price on $40 cost |
|---|---|---|---|---|
| 10% | 9.09% | 10% | 11.1% | $44.44 |
| 20% | 16.67% | 20% | 25% | $50.00 |
| 25% | 20% | 25% | 33.3% | $53.33 |
| 30% | 23.08% | 30% | 42.9% | $57.14 |
| 40% | 28.57% | 40% | 66.7% | $66.67 |
| 50% | 33.33% | 50% | 100% | $80.00 |
| 60% | 37.5% | 60% | 150% | $100.00 |
| 75% | 42.86% | 75% | 300% | $160.00 |
| 100% | 50% | 90% | 900% | $400.00 |
| 200% | 66.67% | 95% | 1,900% | $800.00 |
Notice how the right-hand column runs away from you. Every extra point of margin above about 75% costs disproportionately more markup, because you are chasing a denominator that keeps shrinking. A 100% margin is impossible at any price — it would mean the item cost you nothing.
Pricing backwards from a target margin
This is the calculation worth committing to memory: price = cost ÷ (1 − margin). Divide, never multiply. For a 40% margin on a $40 cost: 40 ÷ 0.60 = $66.67. For a 65% margin: 40 ÷ 0.35 = $114.29.
Enter a target margin in the optional field and the calculator does exactly this, then tells you the markup it implies and how far your current price sits from it. On the default $40 cost and $100 price, a 65% target returns $114.29 — $14.29 more per unit than you are charging. Fill in the optional units field and it shows the totals too: 250 units at the current $100 price is $25,000 of revenue and $15,000 of gross profit.
Gross margin is not the margin that pays you
What this tool gives you is gross margin: price minus the direct cost of the item. It does not know about rent, payroll, software, marketing, returns or payment processing. Those come out of the gross profit, and what survives is net margin — usually a fraction of the gross figure.
Two costs deserve special attention because sellers routinely forget them:
- Payment processing. Roughly 2.9% + $0.30 on card and marketplace transactions. On a $20 sale that is about 4.4% of the price — straight off the margin.
- Returns and shipping. A 10% return rate on a physical product does not cut margin by 10%; it removes the whole gross profit on those units and often the outbound shipping too.
The clean way to handle both is to fold them into the cost input rather than admire a gross margin that never arrives. Put your true landed, fee-inclusive cost in the cost field and the margin the calculator returns is one you can actually spend.
What counts as a healthy margin
There is no universal number, and anyone quoting one is selling something. Margin expectations are set by how much work sits between you and the customer. A grocer turning stock over weekly survives on a few percent net; a software business with near-zero marginal cost runs gross margins above 80% and still has to fund the engineering that created the product.
The useful comparison is always within your own sector and against your own history. If your margin is falling while volume is flat, the cause is almost always input costs rising faster than you have repriced — which is a decision you can make today, not a market condition you have to accept.
Where pricing quietly goes wrong
- Discounting against markup instead of margin. A 20% discount off a 33% margin leaves 16.7%. It does not halve your profit — it does far worse.
- Pricing off an old cost. If your supplier raised prices 8% and you did not reprice, you did not lose 8% of margin; you lost 8% of the cost, which is a bigger share of a thinner profit.
- Averaging margin across a catalogue. A blended 45% can easily hide products selling below cost. Run the numbers per SKU.
- Confusing margin with markup in a quote. The margin vs markup gap is 11.4 points at a 40% markup (28.57% margin) and 50 points at a 100% one (50% margin). Quote the wrong one on a large job and the error is measured in thousands.
A pricing estimate, not accounting or tax advice. Check your own figures before you set prices.
How this profit margin calculator works out its numbers
Profit is price − cost. Margin is profit ÷ price × 100; markup is profit ÷ cost × 100. The optional target-margin field solves the same relationship for price: price = cost ÷ (1 − target ÷ 100).
- No fees or overheads are assumed. The calculator uses exactly the cost you enter, so the result is gross margin. Payment processing of roughly 2.9% + $0.30 and any returns allowance have to be added to the cost input yourself.
- Target margin is capped below 100%. At 100% the divisor becomes zero and the required price is infinite, so the field accepts values under 100 only.
- Every figure in the tables above is generated by this calculator, not typed by hand, so the conversion table and the tool cannot drift apart.
- Rounding. Money is rounded to the cent and percentages to two decimals for display; the arithmetic itself is unrounded.
Reviewed September 2026.
Figures reviewed . Every worked example on this page is checked against the calculator above.
Profit Margin Calculator: frequently asked questions
What is the difference between margin and markup?
Margin is profit divided by the selling price; markup is the same profit divided by the cost. A $40 item sold at $100 has a 60% margin and a 150% markup — identical dollars, different denominators.
How do I convert markup to margin?
Margin = markup ÷ (1 + markup). A 50% markup is a 33.33% margin; a 100% markup is a 50% margin. Going the other way, markup = margin ÷ (1 − margin).
What price gives me a 40% profit margin?
Divide the cost by 0.60. A $40 cost needs a $66.67 price. Adding 40% to the cost gives $56, which is only a 28.57% margin — the most common pricing mistake there is.
Why can't I have a 100% profit margin?
A 100% margin would mean the item cost you nothing, because margin is profit as a share of price and cost would have to be zero. Markup has no ceiling; margin can only approach 100%.
Is this gross margin or net margin?
Gross. It uses price minus the direct cost of the unit. Overheads such as rent, payroll, marketing and payment fees come out of that gross profit and determine your net margin.
Should payment processing fees go in the cost field?
Yes, if you want a margin you can spend. Card and marketplace fees of roughly 2.9% + $0.30 are a real per-unit cost; folding them into the cost input gives you a truer figure than a gross margin that ignores them.
What is a good profit margin?
It depends entirely on the sector — grocery runs on a few percent while software often exceeds 80% gross. Compare within your own industry and against your own trend rather than to a universal benchmark.
How much does a discount cost me in margin?
More than the discount looks. Taking 20% off a product carrying a 33% margin leaves about 16.7% — roughly half the profit gone for a fifth off the price.