Profit margin calculator: margin and markup, both ways
Enter the price, the cost and the fees charged on the sale, and see gross margin, net margin, the equivalent markup, the profit for the month and the price that delivers the margin you want. Free, no signup, and nothing leaves your computer.
The sale, one unit at a time
Scale and target
-
Convert margin to markup, and back
Type on one side and the other adjusts. They are the same difference between price and cost, measured on different bases: margin divides by price, markup divides by cost.
Every margin has exactly one markup
The other numbers in the same scenario
- Gross profit per unit
- -
- Gross margin, before fees
- -
- Cost as a share of price
- -
- Price as a multiple of cost
- -
- Fees per unit
- -
- Net profit per unit
- -
- Net markup, after fees
- -
- Price where profit hits zero
- -
- Discount that wipes out profit
- -
- Margin if price rises 10%
- -
- Extra profit from a 10% higher price
- -
- Margin if cost drops 10%
- -
- Extra profit from a 10% lower cost
- -
- Price that hits the target
- -
- Maximum cost for the target
- -
- The mistake price: target used as markup
- -
- Margin that wrong price delivers
- -
- Revenue this month
- -
- Direct cost this month
- -
- Fees this month
- -
Nothing leaves your browser. The math is per unit and excludes fixed cost: rent, payroll and software are paid out of the sum of margins, not deducted from each sale.
This page is about the cost of what you sell: price, direct cost, platform fee and what is left on each unit. It does not overlap with the siblings that deal with the cost of winning the customer. The CAC calculator answers what a buyer costs to acquire, the LTV calculator answers what they leave over a lifetime and the ROAS calculator answers whether the media paid for itself. None of them works without margin, because the margin calculated here is the input to all of them: a ROAS of 4 is excellent at 50% margin and a loss at 15%.
Margin and markup are the same number on different bases
Confusing the two is the most expensive pricing mistake there is, and it happens because both start from the same subtraction. You sell for 189.90 a product that cost 96: the gap is 93.90, and it is what you do with that gap that splits the two paths.
Dividing 93.90 by the price gives 49.45% margin: of every dollar that lands in the till, almost fifty cents were not committed to the product. Dividing the same 93.90 by the cost gives 97.81% markup: you nearly doubled what you paid. Neither is wrong, and neither is truer than the other. The trouble starts when someone asks for 45% and the person on the other side delivers 45 of one kind while the first expected 45 of the other.
Because price is always larger than cost, the markup denominator is always smaller, and markup is always larger than margin. The distance between them grows fast and unintuitively: 20% margin is 25% markup, still close; 50% margin is already 100% markup; 70% margin is 233% markup. The table inside the calculator exists for exactly that reading, and it highlights on its own the step your sale falls on.
How to use it
- Enter the full selling price, the same one the customer pays on the label, with no coupon and no shipping deducted.
- Enter the direct unit cost: what you pay the supplier, or raw material plus direct labor if you make it. Packaging and inbound freight belong here; rent and back office salary do not.
- Add the variable fees charged on the sale: card processing, marketplace commission, tax on revenue. They are a percentage of price, not of cost, which is why they get their own field.
- Fill in units sold per month to see profit at real scale. This field changes no margin, only the size of the number.
- Set the net margin target. The calculator returns the price that delivers it, the maximum cost that still sustains it at the current price and, to close the loop, the price you would get from the mistake of using the target as a markup.
How it works: the formula
Everything comes from one subtraction and two choices of denominator. Fees enter as a fraction of price, which is what makes them shrink margin without touching gross markup.
The last line is the one almost nobody writes down. If your net profit is 40.95% of price, a 40.95% discount consumes exactly that profit and the sale lands at zero. It is not an approximation: net margin is the discount ceiling. Every promo conversation is a conversation about that line, and it is usually held without anyone having calculated it.
Worked example (reproduces the default output)
The prefilled values describe a resale ecommerce store: price of 189.90, direct cost of 96.00, variable fees of 8.5% on the sale, 420 units per month and a 45% net margin target.
- Gross profit per unit: 189.90 minus 96.00 = $ 93.90. Gross margin: 93.90 ÷ 189.90 = 49.45%. Markup: 93.90 ÷ 96.00 = 97.81%. Cost weighs 50.55% of price, and price is 1.98x the cost.
- Fees: 189.90 × 0.085 = $ 16.14 per unit. Net profit: 93.90 minus 16.14 = $ 77.76, which is 40.95% net margin and 81.00% net markup. The fees alone ate eight and a half points of margin.
- Profit hits zero at a price of $ 104.92 (96 ÷ 0.915) and the maximum discount before a loss is 40.95%.
- Raising price by 10% takes net margin to 45.54% and lifts profit per unit by 22.35%. Cutting cost by 10% takes margin to 46.00% and lifts profit by 12.35%. The two moves look symmetric and are not: ten percent of price is worth nearly twice ten percent of cost, because price is the larger base.
- To hit the 45% net margin, price would need to be $ 206.45 (96 ÷ 0.465) or cost would need to fall to $ 88.30. Making the classic mistake, 96 × 1.45 would give a price of $ 139.20 and a margin of just 31.03%, almost fourteen points under target.
- At monthly scale: $ 79,758 in revenue, $ 40,320 in direct cost, $ 6,779 in fees and $ 32,659 in net profit before fixed costs.
Price is worth more than cost, and the math proves it
The example above holds the most useful operating lesson on this page. A 10% price increase and a 10% cost reduction look like equivalent options in any meeting, and they never are. In the default scenario, price delivers 22.35% more profit and cost delivers 12.35%: nearly double, for the same percentage of effort.
The reason is arithmetic. Ten percent of price is 18.99 and ten percent of cost is 9.60, because price is the larger base. The lower your margin, the more brutal this asymmetry gets, and it is precisely at low margin that companies insist on squeezing suppliers instead of touching price. Supplier negotiation feels safer because it carries no volume risk, but it pays less.
Moving price, of course, moves the quantity sold, and that is where the math stops being arithmetic and becomes empirical. It is the question a test answers and a spreadsheet cannot: how to A/B test pricing covers the correct design, and charm pricing deals with endings in 9 and perception bands. If you sell subscriptions, pricing page optimization usually returns more than changing the number itself.
How to read it and where it misleads
The first limit is the fixed cost that is not here. This is a contribution margin per unit: it says what each sale leaves to pay for the rest of the operation, not what the company earns. A 40% net margin can coexist with a loss at month end if volume does not cover the structure. The point where the sum of margins pays the fixed base is a different calculation, and it does not live on this page.
The second is an average fee applied to an uneven mix. Selling on your own site at 4% processing and selling on a marketplace at 16% commission are two different businesses hidden under one average. The honest approach is to run the calculator once per channel. It is usually the difference between a healthy channel and a channel that only generates motion.
The third is an incomplete direct cost. Inbound freight, packaging, breakage and the slice of returns you never recover are all unit cost, and they almost always get left out on the first pass. In ecommerce with high returns, folding returns into average cost moves margin by several points. If your returns come from expectations broken on the page, the conversion rate calculator and page work fix it cheaper than a discount.
The fourth is margin read in isolation. High margin with high acquisition cost is not profit: it is a race between two numbers. Before celebrating the percentage on this page, compare it with what you pay per sale in the CPA calculator. Unit margin is the ceiling on what media is allowed to cost, and that link is what turns this number into a decision.
From number to decision
- If margin is thin and the temptation is to promote, calculate the discount ceiling first and read discount and promo testing: a discount that does not move volume is margin given away.
- If you use free shipping as a lever, the margin here sets the floor of the order that can carry the freight. Free shipping threshold tests show how to find that limit without guessing.
- If margin can fund more media, size how much in the ROAS calculator and the maximum CPC bid.
- If the product has high margin and low volume, the bottleneck is conversion, not price: revenue per visitor shows what a visit is worth today.
- If the cart loses sales after the price was accepted, the money is in checkout: see what it is worth in revenue lost to abandonment.
FAQ
- What is the difference between profit margin and markup?
- Both measure the same gap between price and cost, changing only the base of the division. Margin divides that gap by the selling price and answers how much of every dollar coming in is left over. Markup divides it by the cost and answers how much you added on top of what you paid. A product that costs 96 and sells for 189.90 has 49.45% margin and 97.81% markup, and both numbers describe exactly the same sale.
- How do I convert margin to markup and markup to margin?
- Markup equals margin divided by 1 minus margin. Margin equals markup divided by 1 plus markup. In round numbers: 20% margin is 25% markup, 33.33% margin is 50% markup, 50% margin is 100% markup and 60% margin is 150% markup. The converter at the top of this page runs both directions, and the table right below it lays out the whole ladder.
- How do I price a product from the margin I want?
- Divide the cost by 1 minus the desired margin. For 45% margin on a cost of 96, the price is 96 divided by 0.55, which is 174.55. Multiplying cost by 1.45 is the most common pricing mistake: that price would be 139.20 and would deliver only 31.03% margin, almost 14 points below what you wanted. If card or marketplace fees apply, divide by 1 minus margin minus fee.
- What is a good profit margin?
- It depends on what you sell, which is why this calculator gives a verdict by band instead of a single number. Resale of physical goods usually runs between 10% and 25% net margin, and in that band shipping plus one return eats the profit of a whole order. Services and digital products clear 50% comfortably, but they normally pay a lot to win each sale. Margin only means something when read next to acquisition cost.
- Are gross margin and net margin the same thing here?
- No. Gross margin here is price minus direct cost only. Net margin also subtracts the variable fees charged on the sale: card processing, marketplace commission, tax on revenue. Neither subtracts fixed cost, because rent, payroll and software do not belong to a single unit sold: they are paid out of the sum of every margin in the month.
- How much discount can I give before losing money?
- The maximum discount is exactly your net margin. At 40.95% margin, a 40.95% discount zeroes the profit on that sale, and anything above it is a loss. That is why 50% off campaigns destroy mid margin operations even when they sell a lot: extra volume does not make up for a margin that went negative. The calculator shows this ceiling directly in the table.
Keep going
Margin is what you have; price is what you decide. To turn that decision into an experiment instead of an opinion, start with price anchoring experiments and then put a number on each point of conversion with the revenue impact calculator.