Finance

Margin Calculator Guide: Gross, Net & Operating Margin Explained (2026)

By The hakaru Team·Last updated March 2026
Disclaimer: This guide is for educational purposes only and does not constitute financial or business advice. Profit margin benchmarks vary by industry, business model, and market conditions. Consult a qualified accountant or financial advisor before making pricing or business decisions.

Quick Answer

Gross margin = (Revenue − COGS) ÷ Revenue × 100. For example, if you sell a product for $100 with $60 in costs, your gross margin is 40%. According to NYU Stern (2025), average gross margins vary by industry: software (72%), retail (25%), restaurants (65%). Net margin subtracts ALL expenses including operating costs and taxes.

The 3 Types of Profit Margin

Not all margins are the same. Businesses track three distinct margin metrics, each measuring profitability at a different point in the income statement. Understanding which one you're looking at — and what it excludes — matters more than the number itself.

1. Gross Margin

Gross margin measures how much revenue remains after subtracting the direct cost of producing your product or service (Cost of Goods Sold, or COGS).

Formula: (Revenue − COGS) ÷ Revenue × 100

COGS includes raw materials, direct labor, and manufacturing overhead — anything directly tied to producing what you sell. It does notinclude operating expenses like rent, marketing, or management salaries. Gross margin tells you how efficiently you produce your product before the rest of the business's costs enter the picture.

2. Operating Margin

Operating margin (also called EBIT margin) subtracts both COGS and operating expenses from revenue. Operating expenses include salaries, rent, utilities, marketing, and research & development.

Formula: Operating Income ÷ Revenue × 100

Operating margin is the preferred metric for comparing how well management runs the core business — it strips out interest payments and taxes, which are affected by financing decisions and tax strategies, not operational performance. According to CSI Market, the average operating margin across all U.S. industries was approximately 12.8% in Q4 2024.

3. Net Profit Margin

Net margin is the bottom line — profit after every expense including operating costs, interest on debt, and income taxes.

Formula: Net Income ÷ Revenue × 100

This is what owners and investors care about most. A business with a 40% gross margin might still have a 5% net margin after paying overhead, debt service, and taxes. The gap between gross and net margin reveals your operating cost burden.

Gross Margin vs Markup: What's the Difference?

This confusion causes real financial damage. Margin and markup sound similar and use the same inputs — but they produce different numbers and serve different purposes.

MarginMarkup
FormulaProfit ÷ Selling PriceProfit ÷ Cost
PerspectiveRevenue-basedCost-based
Use caseMeasuring profitabilitySetting prices from cost
Example ($60 cost, $100 price)40%66.7%

A product that costs $60 and sells for $100 has a 40% margin (profit of $40 ÷ selling price of $100). But it has a 66.7% markup(profit of $40 ÷ cost of $60).

If a business owner says “I want 40% profit on this product,” they almost always mean 40% margin. But if they apply a 40% markup instead, the actual margin works out to only 28.6%. That's a meaningful gap — especially at scale.

To convert between them:
Markup to Margin: Margin = Markup ÷ (1 + Markup)
Margin to Markup:Markup = Margin ÷ (1 − Margin)

A 66.7% markup equals a 40% margin. A 25% markup equals a 20% margin.

How to Calculate Gross Margin

Step-by-step with a concrete example.

Suppose your business sells a product for $100 per unit and it costs you $60 to produce (materials, direct labor, packaging).

  1. Calculate gross profit: $100 − $60 = $40
  2. Divide by revenue: $40 ÷ $100 = 0.40
  3. Multiply by 100: 0.40 × 100 = 40% gross margin

At scale, if you sell 10,000 units per month:

  • Monthly revenue: $1,000,000
  • COGS: $600,000
  • Gross profit: $400,000
  • Gross margin: 40%

That $400,000 gross profit must then cover operating expenses before any net profit is recognized. If operating expenses run $250,000/month, operating income is $150,000 — a 15% operating margin.

Use our Margin Calculator to run these calculations instantly for any revenue and cost figures.

Profit Margin Benchmarks by Industry

Context makes margin data meaningful. A 15% gross margin is mediocre for a software company but healthy for a grocery retailer. The table below uses NYU Stern School of Business data (January 2025) for gross margin and CSI Market data for net margin.

IndustryAvg Gross MarginAvg Net MarginNotes
Software (SaaS)71.8%18.4%High fixed costs once built
Restaurants65.2%3.5%High operating & labor costs
Consulting30.4%10.2%Varies by billing rate & utilization
Healthcare33.2%7.1%Heavily regulated, high overhead
Manufacturing18.5%6.8%Material and labor intensive
Retail (general)25.1%2.9%High volume, thin margins

Notice the gap between gross and net margin. Restaurants have a 65% gross margin but only a 3.5% net margin — labor, rent, and utilities consume most of what's left after food costs. Software companies retain much more of their gross profit because scaling a software product costs very little once it's built.

According to IBISWorld, the U.S. small business average net profit margin across all sectors sits around 7.1%. The SBA reports that businesses with fewer than 20 employees typically run net margins between 4% and 9%, depending on the sector.

How to Set Prices for a Target Margin

Working backward from a target margin is more reliable than applying a fixed markup. The formula is:

Price = Cost ÷ (1 − Target Margin)

Examples:

CostTarget Gross MarginRequired Price
$2025%$26.67
$6040%$100.00
$15050%$300.00
$50033%$746.27

This approach anchors pricing to your desired profitability. But pricing also needs to account for market rates — if the market won't pay $300 for your $150-cost product, you either need to reduce costs or accept a lower margin.

For service businesses, the same logic applies but COGS is typically labor cost. If a consultant costs $100/hour in salary and overhead and you want a 50% gross margin, the billing rate must be at least $200/hour.

Top 5 Ways to Improve Profit Margins

Margins improve when revenue grows faster than costs, or when costs fall without losing revenue. Here are five approaches ranked by typical impact.

  1. Raise prices selectively.Even a 5% price increase on existing products flows almost entirely to gross profit. According to McKinsey, a 1% price increase translates to an 8.7% increase in operating profit for the average S&P 500 company — more impact than a 1% reduction in variable costs. Test higher prices on low-competition SKUs first.
  2. Reduce COGS through supplier negotiation or volume.Renegotiate supplier contracts annually. Consolidate suppliers to increase leverage. Consider backward integration — producing key components in-house — when volumes justify it.
  3. Cut low-margin products or clients. The Pareto principle applies to margins: roughly 20% of products or clients often generate 80% of profit. Identify and eliminate the ones dragging down your average margin. Fire bad clients.
  4. Improve operational efficiency.Reduce waste, rework, and idle time in production. Automate repetitive processes. For service businesses, increasing utilization rates (billable hours ÷ total hours) directly improves margins without adding revenue.
  5. Shift mix toward higher-margin offerings. If software has 72% gross margins and services have 30%, growing the software share of revenue improves blended margins. This is why SaaS companies push customers toward self-service products and away from custom professional services.

The fastest lever is almost always pricing. Most small businesses undercharge because they fear losing customers. In practice, price-sensitive customers are often the least profitable anyway.

Calculate your profit margins instantly

Try the Free Margin Calculator →

Frequently Asked Questions

What is a good profit margin for a small business?

A net profit margin of 10% is generally considered good, 20% is excellent, and 5% is average. But benchmarks vary widely by industry. Software companies often see net margins above 20%, while grocery stores operate at 1–3%. Compare your margin to industry peers rather than using a single universal threshold.

What is the difference between gross margin and net margin?

Gross margin only subtracts the direct cost of goods sold (COGS) from revenue. Net margin subtracts all expenses — operating costs, salaries, rent, interest, and taxes. Gross margin tells you how efficiently you produce your product. Net margin tells you how much profit the whole business generates after every cost is paid.

What is the difference between margin and markup?

Margin is calculated as profit divided by selling price. Markup is calculated as profit divided by cost. A product that costs $60 and sells for $100 has a 40% margin but a 66.7% markup. These are not interchangeable — confusing them is one of the most common pricing mistakes.

How do I price a product to achieve a target gross margin?

Use the formula: Price = Cost ÷ (1 − Target Margin). To hit a 40% gross margin on a product that costs $60: $60 ÷ (1 − 0.40) = $60 ÷ 0.60 = $100. This anchors your pricing to your desired profitability.

What is operating margin and why does it matter?

Operating margin measures profit after subtracting COGS and operating expenses, but before interest and taxes. It shows how efficiently management runs the core business — independent of financing decisions or tax strategies. Investors use it to compare companies in the same industry.

What are average profit margins by industry?

According to NYU Stern School of Business (January 2025): software (71.8% gross), restaurants (65.2% gross), retail (25.1% gross), manufacturing (18.5% gross), consulting (30.4% gross), and healthcare (33.2% gross). Net margins are typically 10–15 percentage points lower once operating expenses, interest, and taxes are factored in.

Disclaimer: This guide is for educational purposes only and does not constitute financial or business advice. Margin benchmarks vary by industry, geography, and business model. Consult a qualified accountant or financial advisor before making pricing or business strategy decisions.