The net profit margin formula is net profit ÷ revenue × 100. Net profit is what remains after every cost — product, shipping, fees, ads, salaries, software, and tax — comes out of revenue. Divide that leftover by revenue and multiply by one hundred to get the percentage of each sales dollar you actually keep.

The net profit margin formula

Net profit margin answers one blunt question: of every dollar that comes in, how many cents stay after everything is paid? It is the bottom line of your income statement expressed as a percentage.

The formula is short:

Net profit margin % = (Net profit ÷ Revenue) × 100

Where net profit is Revenue − all costs — cost of goods, shipping, payment fees, fulfillment, ad spend, salaries, software, rent, and tax. Nothing is excluded. That total inclusiveness is the whole point, and it's what separates net margin from the friendlier ratios above it.

This guide walks the formula against a real example store, shows how it differs from gross margin and contribution margin, and flags the denominator traps that quietly inflate the number. For the wider metric family — CAC, LTV, ROAS, AOV — see the ecommerce metrics guide.

A worked example, line by line

Say you run a print-on-demand apparel store and want your monthly net margin. Here's a clean, internally consistent set of numbers to walk — treat them as an illustration, not a market claim.

Say your average order sells for $40. Multiply across a thousand orders and monthly revenue is $40,000. Now subtract, in order:

  • Cost of goods (blank garment, print, base fulfillment): $16 per order → $16,000
  • Shipping: $5 per order → $5,000
  • Payment processing at 4% of $40: $1.60 per order → $1,600
  • Pick and pack labor: $1.40 per order → $1,400
  • Ad spend (Meta plus Google): $10,000
  • Fixed costs (rent, software, one salary): $4,000

Add the costs: $16,000 + $5,000 + $1,600 + $1,400 + $10,000 + $4,000 = $38,000.

Net profit is $40,000 − $38,000 = $2,000.

Net profit margin is ($2,000 ÷ $40,000) × 100 = 5%.

So on $40,000 of sales, you keep $2,000. Every $40 order nets you two dollars once the whole business — not just the product — is paid for. That gap between a healthy-looking 60% gross margin and a 5% net margin is where most store owners get surprised.

Net margin vs gross margin vs contribution margin

The single biggest source of confusion is which costs each margin subtracts. Same store, three very different numbers.

Gross margin subtracts only cost of goods. In the example, ($40 − $16) ÷ $40 = 60%. It tells you whether the product itself is worth making, and nothing about whether the business survives.

Contribution margin subtracts every variable cost — cost of goods plus shipping, fees, fulfillment, and the ad spend allocated to the order. After the non-ad variable costs, $40 − $16 − $5 − $1.60 − $1.40 = $16, a 40% contribution margin. Take out the $10-per-order ad allocation and you're left with $6, or 15%. Contribution margin tells you whether a product is worth selling through this channel at this ad cost.

Net margin subtracts everything, including fixed costs that don't move with volume. That's the 5% you calculated. Gross margin is diagnostic, contribution margin decides what to scale, and net margin is the scoreboard for whether the company made money at all.

The three collapse from 60% to 40% to 5% for the same store. Anyone quoting only the first number is telling a true fact that hides the whole story.

What counts as a "good" net profit margin?

There's no universal target — it depends heavily on your category and model. As a rough anchor, the average ecommerce net profit margin sits in roughly the five-to-ten-percent range, according to Onramp Funds' 2025 benchmarks, with stronger operators pushing higher. Use a benchmark like that to sanity-check your own math, not as a promise about your store.

The example store's 5% would land at the low end of that band — profitable, but with thin cushion. A single fee increase, a shipping surcharge, or a return-rate dip can erase it. That fragility is exactly why the inputs to the formula matter more than the output.

The formula is easy — the inputs are where errors live

The arithmetic of net profit ÷ revenue never trips anyone up. The mistakes hide in what you feed it.

Revenue: gross or net of refunds?

If you divide by gross sales but calculate net profit after refunds and discounts, the two halves of the ratio live in different universes and your margin reads high. Use net revenue — after discounts, refunds, and returns — on both sides. Returns booked weeks later are a classic way a "profitable" month quietly turns average.

Costs: the ones people forget

Net margin only works if every cost is in. The commonly-omitted ones: payment processing fees, chargebacks, software subscriptions, contractor invoices, your own unpaid-founder time, and tax. Leave any out and you've computed operating or gross margin while calling it net.

Ad spend attribution

Ads are usually the largest controllable variable cost, and platform-reported figures over-claim credit. If Meta and Google each take full credit for the same orders, summing their reported revenue inflates your top line and flatters your margin. Judging efficiency store-wide — total revenue over total spend — avoids the double-count. The mechanics of click-based metrics are covered in what CTR is and the CTR formula.

Net margin vs markup: don't confuse the two

Margin is measured against price; markup is measured against cost. For the example order, margin is ($40 − $16) ÷ $40 = 60%, but markup is ($40 − $16) ÷ $16 = 150%. Same $24 gap, two very different percentages. Suppliers and marketplaces quote markup; your income statement quotes margin. Confusing them is a classic pricing error that leaves you underpriced.

How to improve net profit margin

Because net margin is net profit ÷ revenue, only two levers exist: lift the numerator or grow revenue faster than costs. Concretely:

  • Cut cost of goods. A dollar off the blank or print cost drops straight to net profit. On the example order, shaving $16 to $14 adds $2,000 a month at the same volume — it doubles the net profit outright.
  • Trim variable leakage. Renegotiate shipping, reduce payment-fee tiers, fix the pick-pack process. Each is small per order and large per month.
  • Raise average order value. Bundles and thresholds spread fixed costs across more revenue without proportionally more cost. Retention compounds this — see the LTV calculator for how repeat purchases lift lifetime value.
  • Discipline ad spend to true break-even. Your break-even return on ad spend is 1 ÷ contribution-margin ratio. On a 40% contribution margin that's 1 ÷ 0.40 = 2.5. Spend that clears a healthy ROAS on paper but sits below break-even on margin silently drains net profit.

For a full walkthrough of pushing these levers together, read the double-LTV-to-CAC case study.

Where per-order truth beats a spreadsheet

The hard part of net margin isn't the formula — it's assembling every cost per order, across every tool, without missing the fees and returns that hide the real number. That reconciliation is what most stores get wrong.

PodVector connects Shopify, Meta Ads, Google Ads, Printify, and Printful, and computes your true per-order profit from that live data — cost of goods, shipping, processing, and ad allocation netted out, so the margin you see is the margin you actually kept. Victor, its AI operator, analyzes that data and proposes moves, taking Shopify-side actions with your approval; he reads your ad data but does not touch your ad account. It isn't a dashboard you have to interpret — it's the profit math done for you. Connect your store and see your real net margin.

FAQs

What is the net profit margin formula?

Net profit margin equals net profit divided by revenue, multiplied by one hundred. Net profit is revenue minus every cost the business incurs — product, shipping, fees, ads, payroll, overhead, and tax. The result is the percentage of each sales dollar you keep as profit.

How is net profit margin different from gross profit margin?

Gross margin subtracts only the cost of goods sold, so it's always higher. Net margin subtracts everything, including operating costs, marketing, and tax. In the worked example the same store shows a 60% gross margin but only a 5% net margin — the difference is every cost beyond the product itself.

What is a good net profit margin for ecommerce?

It varies by category, but the ecommerce average sits in roughly the five-to-ten-percent range per Onramp Funds' benchmarks. Higher-margin niches and disciplined operators run well above that. Treat any benchmark as a sanity check on your own calculation, not a target you're entitled to.

Why is my net profit margin lower than I expected?

Almost always because a cost was missing from the calculation or ad spend was under-counted. Payment fees, refunds booked later, software, and contractor costs are the usual culprits. If you divide net profit by gross revenue while excluding those costs, the number reads artificially high until reality catches up.

Can net profit margin be negative?

Yes. If total costs exceed revenue, net profit is negative and so is the margin — you lost money on the period. A negative net margin alongside a healthy gross margin usually means your fixed costs or ad spend are too large for your current sales volume.

Is net profit margin the same as markup?

No. Margin is the price-minus-cost gap measured against price; markup measures the same gap against cost. A 150% markup and a 60% margin can describe the exact same product. Always confirm which one a supplier or spreadsheet is quoting before you price off it.