Skip to content
Business Guide

How to Calculate Profit Margin: Formula & Example

Calculate profit margin from revenue and cost, distinguish gross, operating and net margin, and avoid confusing margin with markup.

Content updated: 2026-10-21

The core formula

Gross margin uses cost of goods sold, operating margin adds operating expenses, and net margin also reflects further items such as financing and taxes. A figure labeled simply “margin” is ambiguous without a cost definition.

Profit = Revenue − Cost
Margin = Profit ÷ Revenue × 100

Worked example

$10,000 revenue − $6,500 cost = $3,500 profit and 35% margin.

How to calculate profit margin

  1. Choose the margin definition first: gross, operating or net.
  2. Use revenue and the matching cost definition from the same period.
  3. Subtract cost from revenue to calculate profit under that definition.
  4. Divide profit by revenue and multiply by 100 to express margin as a percentage.

Gross, operating and net margin use different cost layers

Gross margin typically focuses on revenue minus direct cost of goods or services. Operating margin includes operating expenses, while net margin includes the broader set of expenses used to arrive at net profit.

Because the numerator changes with the cost definition, compare like with like. A gross margin should not be compared with another period’s net margin or with a competitor figure that uses a different accounting definition.

Common mistakes

  • Dividing profit by cost, which calculates markup rather than margin.
  • Mixing monthly revenue with annual costs.
  • Changing the cost definition between products or periods without labeling the difference.

Use the calculator

Find gross, operating or net margin from revenue and cost figures.

Open Profit Margin Calculator

Name which margin you are reporting

Gross margin uses cost of goods sold, operating margin adds operating expenses, and net margin also reflects further items such as financing and taxes. A figure labeled simply “margin” is ambiguous without a cost definition.

Compare revenue and costs consistently

Revenue of 25,000 and matching costs of 18,000 produce a 7,000 profit and 28% margin. Mixing monthly revenue with annual expenses would create an invalid percentage.

Frequently asked questions

Can profit margin be negative?

Yes. Margin is negative when the selected costs exceed revenue.

Is gross margin the same as net margin?

No. Gross margin excludes many operating and financing costs that can be included in net margin.

How is margin different from markup?

Margin uses revenue as the denominator; markup uses cost.

What should I verify about compare revenue and costs consistently?

Revenue of 25,000 and matching costs of 18,000 produce a 7,000 profit and 28% margin. Mixing monthly revenue with annual expenses would create an invalid percentage.