Skip to content
Unit economicsMetric 16 of 35

Gross Margin

How much revenue remains after the direct cost of serving customers.

Abderrahim Ben Jazia, PhDBy · Founder of FlowMRR, previously built and sold AIS (Avance Immédiate Services), French tax-credit softwareUpdated:

Put this metric to work: explore FlowMRR's recurring revenue analytics to track revenue movements, retention and forecasts from your Stripe account, or see how FlowMRR compares as a Baremetrics alternative for Stripe.

The percentage of revenue left after direct delivery costs: hosting, support tied to delivery, payment processing, data providers, and other COGS. For SaaS, gross margin is the ceiling on every other efficiency metric.

Formula

Gross Margin = (Revenue − COGS) ÷ Revenue

Worked example

Revenue $100,000, COGS $22,000 → Gross Margin = 78%.

Other definitions you will see

Companies draw the cost-of-revenue line differently: some book payment processing fees or customer success as operating expenses rather than COGS, which raises gross margin, and some report a subscription gross margin, on recurring revenue and its costs only, separately from the margin on services such as onboarding. Compare margins only when the cost lines included match.

Illustrative comparisons

SaaS quality

These unsourced ranges are illustrative scenarios, not measured industry benchmarks, percentiles or recommended targets. Their qualitative labels are editorial interpretations. Compare your own cohorts using the same segment, period, currency and measurement basis.

Excellent
80%+
Healthy
70–80%
Concerning
< 60%

Why it matters

Gross margin decides how much revenue can become product, sales, or profit. It also feeds LTV and CAC payback directly: using revenue instead of gross profit makes unit economics look better than they are. Investors expect software-like margins; below 60%, they'll ask whether you're really SaaS or a services business.

Common mistakes

  • Excluding payment processing or customer support costs because they feel small.
  • Using gross margin inconsistently between LTV and payback calculations.
  • Comparing a services-heavy implementation business to pure software benchmarks.

Calculating it from Stripe data

Stripe supplies the revenue line and one cost line, not the whole margin. For revenue, use subscription revenue earned in the period rather than cash collected: an annual plan paid in January is earned over twelve months, and spreading it avoids a January margin spike followed by eleven weak months. Start from paid invoices, take out tax, which you collect on behalf of the state, and deduct refunds and lost disputes. MRR is a workable proxy while your books for the month are not closed, but it leaves out setup fees and anything billed outside subscriptions.

The cost Stripe does hold is payment processing. Every charge has a balance transaction that records the fee Stripe kept, and disputes carry their own balance transactions and fees; summing them per month gives the processing part of cost of revenue. Everything else in COGS comes from your accounting system: hosting and infrastructure, third-party data and APIs used to deliver the product, the support and onboarding staff who serve existing customers, and the share of implementation work you deliver. Sales, marketing, R&D and general administration stay out: they are operating expenses, not cost of revenue.

Line the periods up on calendar months and one currency. Invoices may be in the customer's currency while fees are recorded in your settlement currency, so convert revenue at the rates your books use, not today's rate. FlowMRR has no cost data: its cash-flow view gives gross receipts, refunds, disputes, Stripe fees and tax per month, and its MRR gives the recurring-revenue side, which you combine with the costs from your books.

Reading the result

Gross margin moves with price, mix and the cost of delivery. A price increase or fewer discounts lifts it without touching costs; a shift toward cheaper plans or heavy-usage customers lowers it even while revenue grows. Infrastructure that scales with usage while you charge per seat erodes margin quietly; if your hosting bill can be split, read margin per plan.

Use one margin everywhere it enters a calculation: LTV, CAC payback and burn analysis. A margin that leaves out support or payment fees overstates all of them. When margin drops, first check which side moved: revenue (refunds, discounts, churn) or costs (a new data provider, a support hire). The fixes are different, and so is the urgency.

Frequently asked questions

What is a good gross margin for a SaaS business?

It depends on how much of delivery is software and how much is people or pass-through costs. A self-serve product that customers run alone keeps more of each sale than one with heavy onboarding, human support or resold data and payments. Compare with businesses that deliver the same way, and watch your own trend.

Are Stripe fees part of COGS?

They are usually treated as cost of revenue, because they scale directly with every sale you collect. Some companies book them as operating expenses instead. Either is defensible if you keep the same choice from period to period and use the same margin in LTV and payback.

What is the difference between gross margin and contribution margin?

Gross margin deducts only the cost of delivering the product. Contribution margin also deducts the other costs that vary with each customer, such as commissions or variable marketing, so it is lower and answers a narrower question: what each additional customer adds before fixed costs.

Can gross margin be calculated from MRR?

As an approximation: (MRR − monthly COGS) ÷ MRR. It differs from the accounting figure because MRR is a run rate at month end that excludes one-off fees, refunds and usage billed separately, while accounting revenue is what was earned during the month.

Contact us
FlowMRR

Let's talk

A question, a technical issue or an idea for a partnership? Write to the FlowMRR team.