Gross margin, operating margin and net margin all divide a profit figure by revenue, but each stops at a different line of the income statement. Gross margin shows what is left after the direct cost of the product. Operating margin also subtracts overhead such as salaries and marketing. Net margin subtracts everything, including interest, taxes and one-off gains.

You are looking at two companies. One reports a 4% margin, the other a 40% margin, and a headline calls the first one "barely profitable." Before you agree, you need to know which margin each number is, because a 4% operating margin can be a sign of a very well-run business in one industry and a warning sign in another.

What is each margin, and how do you calculate it?

Each margin answers a different question about where the money goes. All three use revenue as the denominator.

Margin Formula Question it answers
Gross margin (Revenue minus cost of revenue) / revenue How much does the company keep from each sale after making or buying the product?
Operating margin Operating income / revenue How much is left after running the whole business day to day?
Net margin Net income / revenue How much reaches shareholders after interest, taxes and everything else?

Gross margin

Gross margin measures pricing power and production cost. A coffee shop that sells a $5 drink with $1.25 of beans, milk and cup has a 75% gross margin on that drink. Rent, wages and the espresso machine are not in the number yet.

Operating margin

Operating margin subtracts operating expenses: research and development, sales and marketing, and general and administrative costs. It is often the best single measure of how efficiently the core business runs, because it ignores how the company is financed and what it pays in tax.

Net margin

Net margin is the bottom line divided by revenue. It includes interest expense, investment gains and losses, and income taxes. That makes it the most complete figure, but also the noisiest, because one unusual item can move it a lot in a single year.

What do the three margins look like for real companies?

The clearest way to see the difference is to put two very different businesses side by side. The figures below come from each company's latest annual report on SEC EDGAR: Microsoft's Form 10-K for the fiscal year ended June 30, 2026 and Costco's Form 10-K for the fiscal year ended August 30, 2026. Dollar amounts are in millions. They are used only as teaching examples, not as a view on either stock.

Microsoft (FY2026) Costco (FY2026)
Revenue $331,839 $303,154
Cost of revenue / merchandise costs 106,374 264,279
Gross profit 225,465 38,875
Operating income 155,237 11,685
Net income 133,749 9,226
Gross margin 67.9% 12.8%
Operating margin 46.8% 3.9%
Net margin 40.3% 3.0%

Revenue is similar. Almost everything else is not. Microsoft sells software and cloud services, where each extra sale costs relatively little to deliver. Costco sells physical goods at low markups and earns a meaningful part of its profit from membership fees ($5,907 million in fiscal 2026, per the same filing).

One detail worth noticing: Costco's income statement does not show a gross profit line. It lists merchandise costs as an operating expense, so the gross profit above is calculated by subtracting merchandise costs from total revenue. Companies lay out their statements differently, so always check what is inside each line before you compare.

Why is a low margin not automatically bad?

Margins only make sense inside an industry. A warehouse retailer with a 3.9% operating margin and a software company with a 3.9% operating margin are in completely different situations.

What matters more is the combination of margin and volume, and the direction over time. Costco's operating margin rose from 3.8% in fiscal 2025 to 3.9% in fiscal 2026 on $303 billion of revenue. A small change on a very large base adds up to real money. For return on the money shareholders put in, look at return on equity alongside margins.

How can net margin mislead you?

Net margin can rise or fall for reasons that have nothing to do with how the business is running. Microsoft is a good example. Its net margin rose from 36.1% in fiscal 2025 to 40.3% in fiscal 2026, while its operating margin moved only from 45.6% to 46.8%.

The gap comes from the "other income (expense), net" line, which swung from a loss of $4,901 million in fiscal 2025 to a gain of $10,697 million in fiscal 2026, according to the 10-K. Investment gains, currency effects and interest can all sit in that line. When net margin moves much more than operating margin, read the notes and the MD&A to find out why before treating the improvement as lasting.

Which margin should you focus on?

Each margin is useful for a different job, so read all three together.

Use gross margin to judge pricing power

A falling gross margin can mean rising input costs the company cannot pass on, or heavier discounting. A stable or rising gross margin during a period of inflation suggests customers accept the price.

Use operating margin to judge efficiency

If gross margin holds steady but operating margin falls, overhead is growing faster than sales. That can be a deliberate investment (new research spending) or a cost problem. The MD&A section of the 10-K is where management has to explain it.

Use net margin to check the full picture

Net margin tells you what actually reached shareholders. Compare it with earnings per share and with cash from operations, because profit that never turns into cash is worth less than it looks.

A five-step margin checklist

  1. Pull three years of income statements from SEC EDGAR, not just one.
  2. Calculate gross, operating and net margin for each year yourself.
  3. Check whether the company reports a gross profit line, and what sits inside cost of revenue.
  4. Compare the margins with two or three direct competitors, not with the market as a whole.
  5. When net margin and operating margin move apart, find the line that caused it.

Frequently asked questions

What is a good operating margin?

There is no single number. It depends on the industry, so compare a company with its own history and with direct competitors rather than with an overall benchmark.

Is EBITDA margin the same as operating margin?

No. EBITDA margin adds depreciation and amortization back to operating income, so it is usually higher. See what EBITDA is for why that difference matters.

Can gross margin be negative?

Yes. If it costs more to produce or buy a product than the company sells it for, gross profit is negative. It happens in early-stage companies and in price wars.

Why does net margin sometimes exceed operating margin?

When other income, such as investment gains or interest income, is larger than interest expense and taxes combined, income can rise below the operating line. It is uncommon and worth investigating when it happens.

This page is educational and not investment advice.

Related: How to read an income statement · What is EBITDA? · What is free cash flow? · How to compare two companies in the same industry