Gross Margin Calculator
Gross margin, gross profit, and markup — at the unit and aggregate level. Reverse-solve for the price you need to hit a target margin. Industry benchmarks for SaaS, e-commerce, restaurants, services, manufacturing, retail, and construction.
Optional. Adds a benchmark band so "65% margin" lands in context (great for SaaS, exceptional for restaurants).
Gross profit: $600,000 on $1,000,000 revenue.
Same dollars of gross profit; different denominator. Confusing the two is the #1 source of pricing errors in small business.
Generic — varies widely by industry.
Gray = COGS. Green = gross profit. The green portion is the fraction of every revenue dollar that funds operating expenses, debt service, and profit.
View the TypeScript implementation on GitHub: packages/calc/src/gross-margin.ts · view tests
Gross margin math at a glance
Key facts
- Margin vs. markup
- Margin is gross profit as a percentage of price; markup is gross profit as a percentage of cost. A $100 product with $40 cost has $60 of gross profit — a 60% margin but a 150% markup. Margin is bounded 0–100%; markup has no upper bound.
- The conversion
- Markup = Margin ÷ (1 − Margin), and Margin = Markup ÷ (1 + Markup). A 25% margin is a 33.3% markup; a 50% margin is a 100% markup; a 75% margin is a 300% markup. The relationship is not symmetric.
- What belongs in COGS
- COGS is the direct cost of producing what you sold: raw materials, direct labor, freight-in, payment processing, and per-unit third-party costs. Rent, marketing, R&D, and general overhead sit below gross profit as operating expenses.
- Industry benchmarks
- Typical gross margin bands per Damodaran's NYU Stern dataset: SaaS 70–85%, e-commerce 25–45%, restaurants 60–70% on food cost, professional services 30–50%, manufacturing 25–35%, retail 30–45%, construction 15–25%.
- Link to break-even
- Quick mental math: with fixed costs of $X per month and a gross margin of M%, you need roughly $X ÷ M of monthly revenue to break even — a higher gross margin lowers break-even more than proportionally.
Benchmarks per Damodaran NYU Stern Industry Margins; margin/markup conventions per Garrison/Noreen/Brewer Managerial Accounting (17th ed.). Updated May 2026.
Margin vs markup — the conversion table
Same dollars of gross profit, two different ways to talk about them. Memorize the row that matches your industry — it's the single most useful pricing fact in retail and B2B services.
| Margin (% of price) | Markup (% of cost) |
|---|---|
| 10.0% | 11.1% |
| 20.0% | 25.0% |
| 25.0% | 33.3% |
| 33.3% | 50.0% |
| 50.0% | 100.0% |
| 60.0% | 150.0% |
| 75.0% | 300.0% |
| 90.0% | 900.0% |
If a vendor says "50% markup" they mean a 33.3% margin. If they say "50% margin" they mean a 100% markup. The relationship is not symmetric. Mistaking these is the #1 source of pricing errors in small business.
What this means
Gross margin is the cleanest read on whether your pricing and sourcing are working. It's the share of every revenue dollar that survives after paying for the thing you sold — which is the dollar that has to cover everything else: payroll, rent, marketing, R&D, debt service, and ultimately profit. A higher margin doesn't just buy you more profit; it buys optionality. A 75% gross-margin business can spend more on growth at the same revenue base than a 35% gross-margin business — by a wide margin. Margin compounds.
Industry context matters more than the absolute number. 65% margin is below average for SaaS (typical 70–85%) but excellent for a restaurant on food cost (typical 60–70%) and likely a miscoding error for construction (typical 15–25%). Use the industry preset to put your result in the right band; if you're below the band, the diagnostic is almost always one of: (a) input cost increases not passed through to price, (b) sales-mix drift toward lower-margin lines, (c) misclassified COGS pulling overhead into the wrong bucket, or (d) legitimately fierce competition forcing price compression.
Worked example
A SaaS company sells at $100/month with $25 of monthly per-customer cost (payment processing, transactional email, per-seat hosting). Revenue per customer = $100, COGS per customer = $25 → gross margin 75%, markup 300%. At 1,000 customers: $100K revenue, $25K COGS, $75K gross profit. Industry context: 75% sits at the lower end of typical SaaS (70–85%), suggesting either a service-revenue mix or unusually high per-seat costs. Operating margin will be lower after fixed costs (engineering payroll, sales, marketing).
Compare against an e-commerce company with the same $100K revenue running 35% margin (typical e-commerce): they generate $35K of gross profiton the same top line. The SaaS company can spend $40K/year more on marketing, R&D, or salaries on the same revenue base and still break even at the gross-profit line. Margin compounds— it's why software businesses can outspend physical-goods businesses for customer acquisition and still pencil.
Frequently asked questions
The information and tools on this website are for general educational purposes only and do not constitute financial, investment, legal, or tax advice. Consult a licensed professional for decisions specific to your situation.