Ecommerce · 28 Oct 2026
Margin vs markup: the difference, with examples
Margin is profit as a share of the price; markup is profit as a share of cost. See the formulas, two-way conversion tables and how to price on landed cost.
Key takeaways
To calculate profit margin, subtract your costs from your revenue, divide the result by revenue, and multiply by 100. The only question is which costs you subtract. Take away just the cost of the products and you get gross margin. Take away running costs too and you get operating margin. Take away everything, including interest and tax, and you get net margin.
| Margin | Formula | What it tells you |
|---|---|---|
| Gross margin | (Revenue − Cost of goods sold) ÷ Revenue × 100 | How much each sale leaves after paying for the product |
| Operating margin | Operating profit ÷ Revenue × 100 | How much is left after running the business (ads, software, wages, rent) |
| Net margin | Net profit ÷ Revenue × 100 | What you actually keep after every cost, interest and tax |
Start with a single unit. Say a phone stand costs you $12 and sells for $30.
Use the price before VAT or sales tax, and make the cost your landed cost: the supplier price plus inbound shipping, packaging and per-order fees. If shipping and fees add $4.50, the cost is $16.50 and the margin drops to 45%. Try your own numbers here:
Here is one month for a small online store, worked through all three margins:
| Line | Amount | Margin |
|---|---|---|
| Revenue (before tax) | $20,000 | |
| Cost of goods sold | −$8,000 | |
| Gross profit | $12,000 | 60% gross margin |
| Ads, software and wages | −$8,000 | |
| Operating profit | $4,000 | 20% operating margin |
| Interest and tax | −$1,000 | |
| Net profit | $3,000 | 15% net margin |
The same store can look very healthy at the gross level and thin at the net level. That's normal, and it's why you should track both. Gross margin tells you whether your pricing works. Net margin tells you whether the business works.
Put the cost in column A and the selling price in column B, then use the same formula in both Excel and Google Sheets:
Copy the formulas down the column to work out margin for every product at once.
It depends heavily on the industry. These are average margins for listed US companies from NYU Stern professor Aswath Damodaran's January 2026 data:
| Industry | Gross margin | Net margin |
|---|---|---|
| Retail (grocery and food) | 26.3% | 1.3% |
| Retail (general) | 33.2% | 5.6% |
| Retail (special lines) | 35.3% | 5.2% |
| Restaurants and dining | 32.2% | 9.4% |
| Household products | 51.0% | 11.7% |
| Software | 71.7% | 25.5% |
| All US companies | 37.8% | 9.7% |
These are large companies with buying power, so treat them as context rather than targets. Small online stores usually need a higher gross margin, because shipping, ads and payment fees cost them more per order.
Profit margin = (Revenue − Costs) ÷ Revenue × 100. Use only the cost of goods for gross margin, add operating costs for operating margin, and include every cost, interest and tax for net margin.
Divide your cost by 0.7. A $35 cost needs a $50 price for a 30% margin, because $15 ÷ $50 = 30%. The markup calculator does this for any target.
Usually, yes. Most people mean profit as a percentage of revenue, which is margin. Some use "profit percentage" for profit as a share of cost, which is markup, so check which one is meant.
Yes. If your costs are higher than your revenue, the margin is below zero and each sale loses money.
Ecommerce · 28 Oct 2026
Margin is profit as a share of the price; markup is profit as a share of cost. See the formulas, two-way conversion tables and how to price on landed cost.
Ecommerce · 23 Oct 2026
About 7 in 10 online carts never become orders. Here is what Baymard Institute's research shows about why, and the checkout fixes that matter most.
Ecommerce · 20 Oct 2026
Start from your costs, pick a target margin and check the numbers before you spend on ads.