Try “wedding”, “budget”, “etsy” or “invoice”.

How to Calculate Profit Margin (With Formulas and Examples)

Learn how to calculate profit margin step by step: the profit margin formula, gross vs net margin with a worked P&L, and what counts as a good margin.

By Jonas Weber ·

You’ve had a good month of sales, the bank balance looks healthy, and you want to know what you actually kept. That’s the question profit margin answers. Knowing how to calculate profit margin lets you price products with confidence, spot when rising costs are eating your earnings, and compare this month with last month in one number. There are three margins worth knowing (gross, operating and net), and they all use the same simple shape: profit divided by revenue. The difference is which costs you subtract first. Below are the formulas, a full worked example and benchmarks from real industry data.

To calculate profit margin, subtract costs from revenue to get profit, divide the profit by revenue, and multiply by 100. Gross margin subtracts only the cost of goods sold. Operating margin also subtracts running costs like rent and software. Net profit margin subtracts everything, including interest and taxes.

How do you calculate profit margin?

Every profit margin formula follows one pattern:

Profit margin % = (Revenue − Costs) ÷ Revenue × 100

The only thing that changes between the three margins is which costs go into that subtraction.

  1. Find your revenue. Total sales for the period, before any costs. Use the same period throughout (a month, a quarter or a year).
  2. Subtract the costs for the margin you want. Only product costs for gross margin, product plus running costs for operating margin, every cost for net margin.
  3. Divide the result by revenue. This turns dollars of profit into a share of each sale.
  4. Multiply by 100 to get a percentage.

A quick example: you sell a print for $40 and it costs you $14 in paper, ink and packaging. Profit is $26. Divide $26 by $40 and you get 0.65, so the gross profit margin is 65%. If you’d rather skip the arithmetic, our profit margin calculator does it from cost and price and shows the markup alongside.

Notice that margin is always measured against the selling price. If you divide profit by cost instead, you’ve calculated markup, a different number. We explain that difference and include a conversion chart in markup vs margin.

The three profit margin formulas

Once you know how to calculate profit margin at one level, the other two take seconds. Each profit margin formula below divides by the same revenue figure.

Margin Formula What it tells you
Gross margin (Revenue − Cost of goods sold) ÷ Revenue Whether each product is priced well
Operating margin Operating income ÷ Revenue Whether the day-to-day business is profitable
Net profit margin Net income ÷ Revenue What you keep after every expense

Gross margin looks only at the direct cost of what you sold: materials, the product you bought for resale, packaging, and the labor that goes into making it. It’s the right margin for pricing decisions, because it shows whether a single sale covers its own costs with room to spare.

Operating margin subtracts operating expenses on top of that: rent, software subscriptions, marketing, marketplace and payment fees, salaries that aren’t part of production. What’s left is operating income, the profit from running the business itself.

Net profit margin subtracts the rest: interest on loans and income taxes. It’s the bottom line, and it’s the number that answers whether the business is worth the time you put in

Gross margin vs net margin: a worked example

Gross margin vs net margin is easiest to see on one set of real-looking numbers. Here’s a month for a small candle business, laid out like a simple profit and loss statement.

Line Amount Margin
Revenue $10,000
Cost of goods sold (wax, jars, wicks, scent, boxes) −$4,000
Gross profit $6,000 60% gross margin
Operating expenses (studio rent, Etsy and payment fees, ads, software) −$3,500
Operating income $2,500 25% operating margin
Interest on equipment loan −$100
Income tax (estimated at 20%) −$480
Net income $1,920 19.2% net profit margin

The arithmetic, line by line:

  • Gross margin: $6,000 ÷ $10,000 = 0.60, so 60%
  • Operating margin: $2,500 ÷ $10,000 = 0.25, so 25%
  • Net profit margin: $1,920 ÷ $10,000 = 0.192, so 19.2%

The same $10,000 of sales produces three very different margins, and each points to a different fix. A falling gross margin means product costs are rising faster than prices. A healthy gross margin with a thin operating margin means overhead is the problem. A big gap between operating and net margin points to debt costs or taxes.

The IRS uses the same split on Schedule C, the form most US sole proprietors file. Line 5, gross profit, is gross receipts minus the cost of goods sold. Line 31, net profit, comes only after total expenses are subtracted. If you file a Schedule C, your gross and net margins are already sitting in its numbers.

What is a good profit margin?

A good profit margin depends heavily on the industry, because some businesses carry far higher product costs than others. Benchmarks are most useful when you compare like with like.

Professor Aswath Damodaran at NYU Stern publishes margins by industry for US companies. In his data as of January 2026, about 6,000 companies averaged a 37.76% gross margin and a 9.74% net margin. General retailers averaged 33.18% gross and 5.61% net, while system and application software averaged 71.72% gross and 25.49% net.

Industry (US, January 2026) Gross margin Net margin
All companies 37.76% 9.74%
Retail (general) 33.18% 5.61%
Apparel 56.88% 3.85%
Software (system and application) 71.72% 25.49%

Two things stand out. First, a high gross margin doesn’t guarantee a high net margin: apparel companies keep 56.88% after product costs but only 3.85% at the bottom line, because marketing, stores and markdowns are expensive. Second, these are public companies with scale. A small handmade or digital product business often has a higher gross margin than a big retailer and a lower net margin while it’s still small, since fixed costs are spread over fewer sales.

So rather than chasing a single good profit margin number from someone else’s business, track your own margins month to month. A steady or rising net profit margin as sales grow is the clearest sign the business is getting healthier.

Common profit margin questions, worked out

What’s a 30% margin on $100? If $100 is the price, a 30% margin is $30 of profit on a $70 cost. If $100 is your cost and you want a 30% margin, divide instead of multiplying: $100 ÷ (1 − 0.30) = $142.86.

Does a 20% margin mean 20% profit? It means 20% profit on the selling price, so $200 of every $1,000 in sales. Measured on cost, the same profit is 25%.

Is a 40% profit margin high? As a gross margin, it’s close to the all-company average in the data above. As a net profit margin, it’s roughly four times that average and very strong.

The profit margin formula, run backward, turns a target margin into a price, and it’s worth memorizing:

Price = Cost ÷ (1 − Target margin)

For a $12 cost and a 60% target margin: $12 ÷ 0.40 = $30. Multiplying $12 by 1.6 would give $19.20, which is a 60% markup and only a 37.5% margin. If you price in markup terms, our markup calculator shows both numbers side by side.

Where small businesses lose margin without noticing

Most margin problems come from costs that never make it into the calculation:

  • Selling fees. Marketplace commissions, payment processing and listing fees come out of every sale. They belong in operating expenses at minimum, and many sellers fold them into product cost for pricing.
  • Shipping and packaging. Free shipping is a cost you pay. Boxes, tape and mailers add up per order.
  • Your own time. If you make the product, labor is part of the cost of goods sold, even when nobody pays you a wage.
  • Discounts and refunds. Price your margin on what customers actually pay after sales and returns, not on the list price.

Recalculate margins whenever a supplier raises prices or a platform changes its fees. A 5% jump in product cost on a 60% gross margin product drops the margin to 58%, small on one sale and noticeable across a year.

Putting it to work

When you calculate profit margin for the business, start with gross margin on each product so every price covers its own costs, then check operating and net margin monthly to see what the business keeps overall. Our profit margin calculator, linked earlier in this post, gives you the margin and markup in one step from any cost and price.

If you sell handmade goods, our guide to how to price handmade items walks through building costs from materials and time.

Questions people ask

What is the formula for calculating profit and loss percentage?

In school math, profit percentage is profit divided by cost, times 100, and loss percentage is loss divided by cost, times 100. That version measures against cost, which is markup. Profit margin measures against the selling price instead: (price − cost) ÷ price × 100. Businesses report margin, so use the price-based formula for pricing and financial checks.

Is a 40% profit margin high?

It depends on which margin. A 40% gross margin is close to average: across about 6,000 US public companies, the average gross margin was 37.76% in NYU Stern's January 2026 data. A 40% net margin is very high, since the same companies averaged a 9.74% net margin. Compare against businesses like yours, not all businesses.

What is a 30% margin on $100?

If $100 is the selling price, a 30% margin means $30 of profit and a cost of $70. If $100 is your cost and you want a 30% margin, divide by 0.7: $100 ÷ 0.7 = $142.86. Your profit is then $42.86, which is 30% of the $142.86 selling price.

Does 20% margin mean 20% profit?

A 20% margin means 20 cents of every sales dollar is profit at that level, so on $1,000 of sales you keep $200. It is a 20% profit on price, which equals a 25% profit on cost. Check which margin is meant too: a 20% gross margin leaves far less once rent, fees and other expenses come out.

What is a 20% markup on $100?

A 20% markup on a $100 cost gives a $120 selling price and $20 of profit. That $20 is 16.67% of the $120 price, so a 20% markup equals a 16.67% margin. Markup is measured on cost and margin on price, which is why the two percentages never match.

What is a good profit margin for a small business?

A good profit margin depends on your industry. In NYU Stern's January 2026 data for US companies, general retailers averaged a 5.61% net margin, while system and application software averaged 25.49%. Track your own net profit margin every month and aim to keep it steady or rising as sales grow.

What is the difference between gross profit and net profit?

Gross profit is sales minus the cost of goods sold, the direct cost of what you sold. Net profit is what remains after every expense, including rent, software, marketing, fees, interest and taxes. Gross profit tells you whether a product is priced well; net profit tells you whether the whole business makes money.

Should gross profit be higher than net profit?

Yes, for almost every business. Net profit starts from gross profit and then subtracts operating costs, interest and taxes, so it ends up smaller. If the two are nearly equal, either your overhead is unusually low or some expenses are missing from the books, which is worth checking before you rely on the numbers.