Margin guide

How to Calculate Profit Margin: Gross, Net, and Target Margin

Learn the formulas for gross profit, gross margin, net profit, net margin, and revenue required to reach a target margin.

Reviewed July 21, 2026

Calculate profit margin

Profit is a dollar amount. Profit margin is profit expressed as a percentage of revenue. That distinction makes businesses of different sizes easier to compare and helps a seller see whether growth is actually improving the economics.

Gross margin subtracts cost of goods sold from revenue. Net margin goes further by subtracting operating costs. For a useful comparison, every number needs to cover the same product, order, or accounting period.

The gross margin formula

Gross profit equals revenue minus cost of goods sold. Gross margin equals gross profit divided by revenue, multiplied by 100. If revenue is $100 and cost of goods is $40, gross profit is $60 and gross margin is 60%.

The net margin formula

Net profit subtracts operating costs from gross profit. Net margin divides that result by revenue. Marketplace fees, software, labor, advertising, refunds, and overhead need consistent placement if you compare months.

Reverse a target margin into required revenue

When costs are known, required revenue equals total costs divided by one minus the target margin as a decimal. If total costs are $70 and target margin is 30%, required revenue is $100.

Avoid mixing margin and markup

Margin divides profit by revenue. Markup divides profit by cost. A product bought for $50 and sold for $100 has a 100% markup but a 50% margin. Using the wrong denominator produces pricing mistakes.

Sources

Frequently asked questions

What is the formula for profit margin?

Profit margin equals profit divided by revenue, multiplied by 100.

What is the difference between gross and net margin?

Gross margin subtracts cost of goods sold. Net margin also reflects operating costs and other expenses included in the calculation.

Can profit margin be negative?

Yes. When total costs exceed revenue, profit and the corresponding margin are negative.