In Excel: margin is profit divided by the selling price: =(Price-Cost)/Price, formatted as a percentage.
Margin is profit ÷ price; markup is profit ÷ cost.
Profit per unit: €25.00
Need it as an auditable file?
The pricing model ships inside the Corporate Finance Suite — formula-driven, unlocked, audit-ready.
Need it as an auditable file?
Ships inside the linked template — formula-driven, unlocked, audit-ready.
What this does
Margin and markup use the same profit in the numerator and different denominators, which is why the two numbers never agree and why quoting one as the other misprices a product. Margin divides profit by the price, so it answers what share of revenue you keep and can never reach 100%. Markup divides the same profit by the cost, so it answers how far you marked the item up and has no upper limit. The same idea underpins a lot of everyday Excel work, so the few minutes spent getting it right here pay back across every sheet you build afterwards. Treat it as a pattern, not a one-off, and it stops being something you look up and starts being something you reach for. Treat “calculate profit margin on excel” as a small repeatable workflow rather than a one-off click you hope to remember next time. Use a small test block before the live file, so any surprise in the affected cells shows up while it is still harmless. When a formula is involved, keep the inputs labelled beside it, reference cells instead of typing values, and apply number formatting only after the result checks out. That turns a calculation you can defend to a CFO or an auditor into a method you can reuse, explain, and defend when the workbook leaves your screen.
A worked example
An item costs 60 and sells for 100. Margin is (100-60)/100 = 40%. Markup on the same pair is (100-60)/60 = 66.7%. To hit a target margin instead, work backwards: price = cost / (1 - margin), so 60 / (1 - 0.40) = 100. The two ratios are one keystroke apart in a spreadsheet and several points apart in the price list, and the mistake only surfaces when the year-end gross profit misses plan. A practical tip before you scale it up: build it once on a small block of test data, confirm the number against the tool on this page, and only then point it at your real sheet. That one habit catches almost every mistake while it is still cheap to fix, long before a wrong figure reaches a report or a colleague.
In Google Sheets
If you are in Google Sheets rather than Excel, the good news is that the formula shown here is identical and the workflow barely changes — menus sit across the top instead of in a ribbon, and a few function names differ slightly, but anything you build here moves across with little or no rework. Nothing on this page is behind a login: the tool runs entirely in your browser, the formula is shown in full with one-click copy, and the steps work the same on Windows and Mac. That is the whole promise here — the exact answer, a way to prove it on your own numbers, and just enough context to make it stick. If you take one thing from this page on “calculate profit margin on excel”, make it the habit rather than the keystrokes: set the problem up with labelled inputs, reference those cells, and let Excel do the recomputing. Bookmark the page for the syntax, but do the example once in a blank sheet and check it against the tool above — five minutes of hands-on practice fixes the method in memory far better than re-reading, and it surfaces the small snags while they are still harmless. After that the technique is genuinely yours: faster than searching for it again, and reliable enough to drop into work that other people depend on.
Common mistakes
- Dividing profit by cost and labelling it margin, which overstates the figure on every item.
- Adding a 40% markup and reporting a 40% margin: the first gives a 28.6% margin, and the gap grows as the numbers rise.
- Averaging the margin percentages of several products instead of computing total profit over total revenue.
- Leaving the result as a decimal, so 0.4 is read as 0.4% in a report.
Frequently asked questions
What is the difference between margin and markup?
Margin divides profit by the price, markup divides the same profit by the cost. A 50% markup is a 33.3% margin.
How do I price for a target margin?
=Cost/(1-Margin). For a 35% margin on a cost of 65, that is 65/0.65 = 100.
How do I convert markup to margin?
=Markup/(1+Markup), and back again with =Margin/(1-Margin).
Can margin exceed 100%?
No. Profit cannot exceed the price it is measured against, so a figure above 100% means markup was computed instead.
Other ways people ask this
On the way here you may have searched this as “how to calculate gross profit margin in excel”, “calculate profit margin excel”, “how do you calculate profit margin in excel” and “how to calculate a profit margin in excel” — it is all the same task, and this page is the single, complete answer to it.
Why do people search for this in so many different ways?
Because the same task has many names. “how to calculate gross profit margin in excel”, “calculate profit margin excel”, “how do you calculate profit margin in excel” all point at the one operation explained on this page, which is why they all lead here.