Profit Margin vs Markup

Excel Formulas › Financial

All versionsRatios

Margin and markup are easy to confuse — and the difference costs real money. Margin is profit as a percent of the selling price; markup is profit as a percent of the cost. Same dollars, different denominators.


Quick formula: for a cost in B1 and a price in B2:
=(B2 - B1) / B2 // profit margin =(B2 - B1) / B1 // markup
Margin divides profit by price; markup divides the same profit by cost. A $40 item costing $25 has a 37.5% margin but a 60% markup.

Functions used (tap for the full reference guide):

The example

Cost $25, price $40 — the same $15 profit, two percentages.

AB
1MeasureValue
2Cost$25
3Price$40
4Margin (÷ price)37.5%
5Markup (÷ cost)60%

The formula

Margin and markup from the same cost and price:

=(B2 - B1) / B2 → 37.5% margin =(B2 - B1) / B1 → 60% markup

How it works

Same profit, different base:

  1. The profit is price − cost = $40 − $25 = $15 either way.
  2. Margin divides that by the price: 15/40 = 37.5% — the share of revenue you keep.
  3. Markup divides it by the cost: 15/25 = 60% — how much you added on top of cost.
  4. Markup is always the larger number. Quoting a “60% markup” as if it were margin overstates profitability badly.

Price from a target margin: to hit a 40% margin, divide cost by (1 − margin): =B1 / (1 - 0.4). To apply a markup instead, multiply: =B1 * (1 + 0.6). Mixing these up is the classic pricing error.

Try it: interactive demo

Live demo

Set cost and price; compare margin and markup.

Margin:   Markup:

Variations

Price for a target margin

Divide cost by (1 - margin):

=B1 / (1 - 0.40)

Price from a markup

Multiply cost by (1 + markup):

=B1 * (1 + 0.60)

Convert markup to margin

The relationship:

=markup / (1 + markup)

Pitfalls & errors

Don’t confuse the two. Margin divides by price, markup by cost. Treating a markup as a margin overstates profit and underprices your product.

Divide-by-zero. A zero price (margin) or zero cost (markup) errors. Guard with IFERROR if inputs can be blank.

Pricing direction. For a target margin, divide cost by (1−margin) — not multiply. Multiplying applies a markup, which yields a smaller margin than intended.

Practice workbook

📊
Download the free Profit Margin vs Markup practice workbook
A margin-vs-markup calculator with live formulas, the price-from-target and conversion variants, plus 4 challenges with answers. No sign-up required.

Frequently asked questions

What's the difference between margin and markup in Excel?
Margin is profit divided by price: =(price-cost)/price. Markup is the same profit divided by cost: =(price-cost)/cost. A $40 item costing $25 has a 37.5% margin but a 60% markup.
How do I price an item for a target margin?
Divide the cost by (1 minus the margin): =cost/(1-0.40) prices for a 40% margin. To apply a markup instead, multiply: =cost*(1+0.60).
How do I convert markup to margin?
Use =markup/(1+markup). For example, a 60% markup equals a 37.5% margin.

Stop fighting formulas. Learn them in a day.

This recipe is one of hundreds of real-world formulas we teach. Our Excel Formulas & Functions class covers lookups, logic, text, and dynamic arrays hands-on — live in Dallas–Fort Worth, Houston, Austin, Oklahoma City, Denver, or online.

See the Formulas & Functions Class

Related formulas: Break-even point · Percent change & % of total · ROI & payback period

Function references: IFERROR