Margin vs Markup: Calculator, Formula & Examples
Published by MyBreakeven. Editorial standards and corrections. Report a calculation or content issue to mybreakeven1@gmail.com.
Calculate margin and markup, compare discounts and find the selling price for your target. Use worked examples and clear formulas on one cost basis.
Choose the percentage you actually need
The existing widget converts cost-based markup and sales-based gross margin on one cost basis. Operating margin is a separate statement ratio. A discount or return also changes the net-revenue denominator.
Navigation and planning connections reviewed November 17, 2026.
If you confuse margin vs markup, you can price a profitable-looking sale too low or misread how much money your business actually keeps. Markup is the percentage you add to your cost; margin is the percentage of your selling price that remains after cost, so the two percentages are not interchangeable.
Quick answer: Markup starts with cost and tells you how much you add to reach a price. Margin starts with the selling price and tells you how much of that price is gross profit. A 50% markup does not create a 50% margin: $100 of cost becomes a $150 price, leaving $50, or 33.3% margin.
The margin and markup formulas
The simplest way to remember the difference is to ask what number sits underneath the percentage.
Markup uses cost as its base:
> Markup = (Selling price − Cost) ÷ Cost × 100
If an item costs you $40 and you sell it for $60, your gross profit is $20. Your markup is $20 ÷ $40, or 50%.
Margin uses selling price as its base:
> Margin = (Selling price − Cost) ÷ Selling price × 100
With the same $40 cost and $60 price, your margin is $20 ÷ $60, or 33.3%.
Both calculations use the same gross profit dollars. They answer different questions. Markup asks, “How much did I add to my cost?” Margin asks, “What share of my revenue is left after the direct cost?”
That distinction matters when you set prices, compare products, plan discounts, or estimate the money available for overhead. A business owner who says “I need a 40% margin” cannot simply add 40% to cost. To set a target margin, you must work backward from the selling price.
The conversion formulas are useful:
- Margin from markup:
Markup ÷ (1 + Markup) - Markup from margin:
Margin ÷ (1 − Margin)
Use decimals in those formulas. A 40% markup is 0.40 ÷ 1.40, or 28.6% margin. A 40% margin requires 0.40 ÷ 0.60, or 66.7% markup.
Neither measure includes every business expense automatically. Product cost, direct labor, payment processing, shipping, packaging, or other variable costs may need to be included depending on what decision you are making. Be clear about whether you are calculating a product’s gross margin or the business’s final profit.
What changes the answer
The right percentage depends on your purpose and cost definition. A retailer may calculate markup to build a shelf price from wholesale cost. A service business may focus on margin after direct labor and materials. A restaurant may include ingredients and direct preparation costs when reviewing menu economics.
Start by defining “cost.” For a physical product, that might include purchase cost, inbound freight, packaging, and per-unit handling. For a cleaning job, direct labor and supplies may belong in the job cost. For a menu item, ingredients and packaging can be relevant. Do not switch between a narrow product cost and a broader delivered cost while comparing percentages.
Your sales channel also changes the price you need. A direct sale, marketplace sale, wholesale order, and sale through a representative may each have different fees or commissions. If a channel takes a percentage of revenue, calculate the fee before deciding that a target margin is met. A price that works in your store may not work after a marketplace fee.
Discounts change the result too. If your list price is $100 and you offer 20% off, your customer pays $80. A cost of $50 creates $30 gross profit. That is a 60% markup on cost, but only a 37.5% margin on the discounted selling price. The discount did not merely reduce revenue; it reduced the margin rate.
Taxes deserve care. Sales tax collected for an authority is generally not your sales revenue, while income tax is considered later in the profit picture. Keep those concepts separate in your worksheet.
Use the measure your audience understands. If a supplier asks for a markup, respond with markup. If you are setting a gross-margin target, calculate margin. When in doubt, show dollars as well as percentage: cost, price, gross profit, margin, and markup together remove ambiguity.
Worked examples: converting margin and markup
Scenario 1: A product sale
You buy a product for $24 and sell it for $36.
- Gross profit: $36 − $24 = $12
- Markup: $12 ÷ $24 = 50%
- Margin: $12 ÷ $36 = 33.3%
If you want a 50% margin, do not price it at $36. Use the target-margin formula:
> Price = Cost ÷ (1 − Target margin)
So the required price is $24 ÷ (1 − 0.50) = $48. At $48, gross profit is $24, which is 50% of the selling price. The markup is 100%.
Scenario 2: A house-cleaning job
Suppose a two-hour cleaning job has $44 of direct labor and $6 of supplies, for a direct cost of $50. You quote $80.
- Gross profit: $80 − $50 = $30
- Markup: $30 ÷ $50 = 60%
- Margin: $30 ÷ $80 = 37.5%
The $30 is not necessarily take-home profit. It may need to cover scheduling time, insurance, software, travel that was not included in the job cost, advertising, rent, and other operating expenses. For more context on building a service price, see ways to lower your break-even point.
If your goal is a 45% margin on the defined $50 direct cost, the quote would be $50 ÷ 0.55 = $90.91. Gross profit would be $40.91, and $40.91 ÷ $90.91 is 45%.
Scenario 3: A restaurant menu item
A menu item has ingredient and direct packaging costs of $8. You price it at $20.
- Gross profit: $20 − $8 = $12
- Markup: $12 ÷ $8 = 150%
- Margin: $12 ÷ $20 = 60%
That 60% margin is based only on the costs you included. It does not prove the item is profitable after payroll, rent, utilities, delivery fees, waste, and other expenses. Use the result to compare menu items consistently, then review the broader business numbers. This calculate your break-even point explains the pricing logic in a menu setting.
A margin-versus-markup worksheet you can check
Put your defined unit cost in A2 and actual selling price in B2. These formulas work in Excel or Google Sheets; they are instructions for your own sheet, not a downloadable template. Format ratio cells as percentages without also multiplying by 100.
| Output | Formula | Cost $70; price $100 |
|---|---|---|
| Profit on the stated cost basis | =B2-A2 | $30 |
| Markup on cost | =(B2-A2)/A2 | 42.86% |
| Margin on sales | =(B2-A2)/B2 | 30% |
For a target margin entered as 30% in C2, price is =A2/(1-C2). With a separate 3% fee in D2, it becomes =A2/(1-C2-D2), provided the cost in A2 excludes that fee and the denominator is positive. $70 ÷ 0.67 requires $104.48 when rounded upward to cents. This is margin after the defined costs, not automatically accounting gross or net margin.
Zero cost makes percentage markup undefined; zero revenue makes margin undefined. A zero-cost item sold for a positive price can have 100% margin on that narrow cost basis but still incur selling costs. Do not replace undefined results with a reassuring 0%. For a discounted offer, substitute the collected price and use discount volume recovery to check the extra sales needed.
How to run your own numbers
Make a small table for each product, job, or service. Put the unit cost in one column, the actual selling price in another, and calculate gross profit as price minus cost. Then calculate both percentages so you can see whether someone has used the wrong term.
For a current sale, use:
- Gross profit = Price − Cost
- Markup = Gross profit ÷ Cost
- Margin = Gross profit ÷ Price
For a target markup, use:
> Price = Cost × (1 + Markup)
A $70 cost with a 30% markup produces a $91 price: $70 × 1.30. Gross profit is $21, so margin is $21 ÷ $91, or about 23.1%.
For a target margin, use:
> Price = Cost ÷ (1 − Margin)
A $70 cost with a 30% margin requires $100: $70 ÷ 0.70. Gross profit is $30, exactly 30% of $100.
Enter the numbers in the MyBreakeven calculator to test price, cost, and break-even assumptions together. Round the customer-facing price only after doing the calculation. Then recalculate from the rounded price, because rounding can change the actual margin.
Run a second version that includes variable fees. For example, if a sale has a $5 cost and a 10% marketplace fee, a target margin cannot be checked by subtracting only $5. Use a consistent formula for the fee and price. If the fee is a percentage of price, solve for the price rather than guessing.
Finally, test a range of prices. Compare the expected gross profit dollars, not just the percentage. A lower-margin item may produce more dollars if it sells in much greater volume, while a high-margin item may be slow or expensive to sell. Pricing is a decision about both economics and demand; the calculation gives you a clear floor, not a guaranteed sales forecast.
Common mistakes
Calling markup margin. This is the classic error. Always identify whether the denominator is cost or selling price.
Adding a target margin to cost. Adding 40% to cost creates a 28.6% margin, not a 40% margin. Use cost divided by one minus the target margin.
Ignoring discounts. Evaluate the price customers actually pay, not just the list price. If discounts are common, build them into your pricing decision.
Leaving out direct costs. Materials, direct labor, packaging, freight, commissions, and transaction fees can materially change the result. Define your cost consistently.
Treating gross margin as net profit. Gross profit still has to support overhead and other expenses. A strong product margin does not guarantee a profitable company.
Rounding too early. Keep full precision through the calculation, then round the final price and verify the result.
Comparing unlike calculations. One product’s margin may include shipping and fees while another’s includes only purchase cost. Use the same cost rules before drawing conclusions. For more practical pricing guidance, explore the small business guide library.
Using a percentage without dollars. A percentage can sound impressive while the gross profit dollars are too small to support your operation. Show both.
Closing takeaways
- Markup is based on cost; margin is based on selling price.
- A target margin requires division by one minus the margin, not a simple addition to cost.
- Include the direct costs and channel fees that belong to the decision.
- Check the actual discounted price and report dollars alongside percentages.
- Use margin and markup together when you want pricing decisions that are easy to explain and hard to misread.
Preserve a target margin after a planned discount
If cost is $70 and the target margin is 30%, the required collected selling price is $100. To offer 20% off while retaining that price, the list price is $100 ÷ 0.80 = $125. Marking a $100 item down by 20% instead collects $80, leaving $10 and a 12.5% margin on the same $70 cost.
The markup versus margin calculator rounds a target selling-price floor upward to cents, then rounds the discount-adjusted list-price floor upward. Recheck the collected price against the defined cost. At a 100% discount, no finite list price can collect a positive target selling price. These price floors do not predict demand or extra sales.
For the basic denominator distinction, see AccountingCoach’s margin and markup explanation. The discount-adjusted list-price example above is an original application of the stated formulas.
Keep gross margin, revenue fees and the inventory cost basis separate
In a separate fictional USD example, an item sells for $100 and its defined inventory cost is $60. Gross profit is $40, gross margin is 40% of sales, and markup is 66.67% of the $60 cost. If the sale also incurs a 5% revenue fee and a $2 transaction cost outside that cost base, contribution is $100 − $60 − $5 − $2 = $33. Calling the 40% gross margin a 40% after-fee margin would overstate what remains.
To leave 35% of collected price after those stated costs, solve P × (1 − 0.05 − 0.35) = $60 + $2. The exact price is $103.3333…, rounded upward to $103.34. At $103.33 the amount after costs is $36.1635, below the required $36.1655; at $103.34 it is $36.173, above the $36.169 requirement. Keep full precision through the boundary check. This is a cost-defined target, not a forecast that buyers will accept the price.
The $60 cost base also needs a consistent policy: inventory valuation methods can change which supported batch cost flows to sold units. For a service, employee compensation and productive hours help define the labor cost base without counting an annual salary and its paid leave wages twice. These are different decisions from the markup percentage itself.
Frequently asked questions
Is a 50% markup the same as a 50% margin?
No. A 50% markup means a $100 cost becomes a $150 price, creating $50 gross profit. The margin is $50 ÷ $150, or 33.3%. A 50% margin on a $100 cost requires a $200 price, which is a 100% markup.
Which is better for pricing: margin or markup?
Use the measure that matches the decision. Markup is convenient when you start with cost and add an amount. Margin is useful when you need a defined share of revenue left after direct cost. Many businesses track both to avoid confusion.
How do I convert markup to margin?
Divide the markup by one plus the markup. For a 25% markup, calculate 0.25 ÷ 1.25 = 20% margin. The reverse is margin divided by one minus margin.
Can margin be higher than 100%?
For a standard sale with positive cost, gross margin cannot exceed 100% because gross profit is part of the selling price. Markup can exceed 100% when the selling price is more than twice the cost.
Should labor be included in cost?
Include direct labor when you are evaluating the economics of a job or service. Whether to include owner time, overhead, or administrative labor depends on the question. State your cost definition and use it consistently.
Why does my margin fall after a discount?
A discount lowers the selling price while the direct cost may stay the same. Since margin divides gross profit by the lower selling price, both the gross-profit dollars and margin percentage usually decline.
Do I need both numbers in my reports?
Keeping both can help, especially when suppliers, sales staff, and managers use different terminology. At minimum, show cost, selling price, gross profit dollars, and the percentage label so the calculation is transparent.
Planning estimates only—not accounting, tax, legal or lending advice.