Profit Margin Calculator

Gross profit, margin percentage and markup from revenue and cost.

Quick answer

  • Formula: Margin = (Revenue − Cost) / Revenue × 100; Markup = (Revenue − Cost) / Cost × 100
  • Worked example — Gross profit: $40.00 (full example below).

Profit Margin Calculator

Worked example result
Gross profit$40.00
Profit margin40.00%
Markup66.67%

Selling at $100 what cost $60 makes a $40 profit — a 40% margin but a 66.67% markup. Same profit, two different percentages.

Diagram: how the Profit Margin Calculator works — you enter Revenue (selling price), Cost; it applies the formula Margin = (Revenue − Cost) / Revenue × 100; Markup = (Revenue − Cost…; and the worked example gives Gross profit: $40.00.
How the Profit Margin Calculator works — the inputs, the formula, and a worked example (Gross profit: $40.00).

Margin and markup are the two most-confused numbers in business. Enter revenue and cost: this calculator returns the gross profit, the margin (profit as a share of the price) and the markup (profit as a share of cost).

The formula

Margin = (Revenue − Cost) / Revenue × 100; Markup = (Revenue − Cost) / Cost × 100

Worked example

Selling at $100 what cost $60 makes a $40 profit — a 40% margin but a 66.67% markup. Same profit, two different percentages.

Worked example for the Profit Margin Calculator: with Revenue (selling price) 100, Cost 60, the result is Gross profit: $40.00; Profit margin: 40.00%.
The worked example, with the example values entered and the results they give.

The example is pre-loaded in the result panel — press Calculate with your own numbers to replace it.

Frequently asked questions

Why are margin and markup different?

They divide the same profit by different bases: margin uses the selling price, markup uses the cost. Margin can never exceed 100%; markup can.

What is a healthy margin?

It varies enormously by industry — grocery retail often runs 1–3% net margins while software can exceed 70% gross. Compare within your own industry.

Category: Finance calculators

Sources & methodology

This calculator applies the formula shown on this page exactly as written, using the standard definitions for its inputs. Results are computed from the values you enter — no data is stored — and are rounded only for display.

Content last reviewed by CalcHub Editorial.

Embed this calculator on your site

Free to use with attribution — paste the snippet below and the calculator appears on your page, with a link back to CalcHub.

<iframe src="https://calc-hub-63e.pages.dev/embed/profit-margin-calculator" width="100%" height="640" style="border:1px solid #d9e2ea;border-radius:12px" loading="lazy" title="Profit Margin Calculator — CalcHub"></iframe>

Open the embed version →