Who it's for: SaaS finance team members who map the chart of accounts, allocate costs or report gross margin to the board and investors.
What you'll get: the common definition of SaaS gross margin and its variations, a line-by-line table of what typically sits in cost of sales, how to allocate shared costs, a worked MonthEndClub Co Ltd example with journals, and a one-slide summary for your boss.
Reading time: about 11 minutes. Less time than the argument about where the support team sits.
Why gross margin gets so much attention
Gross margin tells investors how much of each pound of revenue is left to pay for sales, marketing, product development and profit. In SaaS it also feeds other metrics, such as LTV and CAC payback, so a few costs in the wrong place can change several headline numbers at once. The accounting standards don't define "cost of sales" for software, so consistency and a written policy matter more than any single right answer.
Key terms
- Cost of sales (COGS, cost of revenue): the costs of delivering the service customers pay for.
- Gross profit: revenue minus cost of sales.
- Gross margin: gross profit as a percentage of revenue.
- Opex (operating expenses): costs below gross profit: sales and marketing, research and development (R&D), and general and administrative (G&A).
- Allocation: splitting a shared cost (a person's time, a software licence, office rent) between cost of sales and opex using a reasonable, documented basis.
- Subscription gross margin: gross margin on subscription revenue only, excluding professional services.
The formula, and the common variations
Gross margin % = (Revenue − Cost of sales) ÷ Revenue × 100
The common variations are about what goes into each part:
- Total vs subscription gross margin. Many SaaS companies report both. Professional services often run at a much lower margin, so blending them can hide how healthy the subscription business is.
- Including or excluding share-based payments. Some companies report an "adjusted" gross margin excluding share option charges and amortisation of acquired intangibles. Companies that do this typically show the unadjusted figure alongside it.
- Where capitalised development amortisation goes. Some put amortisation of capitalised platform development in cost of sales; others keep it in R&D or a separate line.
- Payment processing fees. Commonly cost of sales; some put them in G&A.
What typically belongs in cost of sales
| Cost | Common treatment | Notes and variations |
|---|---|---|
| Cloud hosting for the live product (production) | Cost of sales | Development, test and staging environments typically go to R&D |
| Third-party software built into the product (APIs, data feeds, email delivery) | Cost of sales | Internal tools used by staff go to opex |
| Customer support team | Cost of sales | Some put tier-one support in cost of sales and account management in sales |
| Customer success | Split | Onboarding and ongoing service often cost of sales; renewal and upsell work often sales and marketing |
| Site reliability, DevOps and on-call engineers running production | Cost of sales (share of time) | Time spent building new features goes to R&D |
| Implementation and professional services staff | Cost of sales (services) | Matched to services revenue |
| Payment processing fees (for example Stripe) | Commonly cost of sales | Some report in G&A; consistency matters most |
| Amortisation of capitalised platform development | Varies | Cost of sales, R&D or a separate line; disclose the choice |
| Allocated overheads (rent, IT, HR) for cost-of-sales teams | Varies | Many smaller companies don't allocate; larger ones often do |
| Sales commissions | Opex (sales and marketing) | Not cost of sales, even when capitalised |
| Product managers and feature engineers | Opex (R&D) | Not cost of sales |
| Marketing and free-trial hosting | Commonly opex | Some argue free-tier hosting is cost of sales; most treat it as marketing |
AI shortcut: export your chart of accounts with this year's balances and the current P&L mapping, then give it to an approved AI assistant along with the table above. Ask it to list accounts whose mapping looks inconsistent with the table and explain why. You'll get a review list, not decisions; a person agrees each change and records it in the policy.
How to set up and run the gross margin split
| Step | What "done" looks like | |
|---|---|---|
| ☐ | Write a one-page cost of sales policy using the table above as a start | Approved by the finance lead and filed |
| ☐ | Map every P&L account to cost of sales or an opex category | No account left unmapped |
| ☐ | Tag cloud costs by environment (production vs development) | Tags in the cloud provider's billing so the split is data, not guesswork |
| ☐ | Agree allocation bases for shared people costs (for example time estimates by team, refreshed quarterly) | Percentages signed off by department heads |
| ☐ | Post a monthly reclassification journal from the source department to cost of sales | Journal with workings attached and approved |
| ☐ | Calculate total and subscription gross margin | Both figures in the pack |
| ☐ | Compare with last month and last year and explain big moves | Variance comment for any change above your threshold |
| ☐ | Review the allocation bases each quarter or when teams change | Dated record of the review |
Worked example: MonthEndClub Co Ltd, November
MonthEndClub Co Ltd (fictional) reports both total and subscription gross margin. Its policy puts production hosting, support, a share of DevOps, payment fees and implementation staff in cost of sales. November figures:
| Item | £ |
|---|---|
| Subscription revenue | 88,500 |
| Professional services revenue | 6,000 |
| Total revenue | 94,500 |
| Cloud hosting invoice (all environments) | 15,000 |
| Engineering salaries and employer costs (DevOps team of 2) | 16,000 |
| Support team salaries and employer costs | 7,500 |
| Implementation consultant salary and employer costs | 4,500 |
| Payment processing fees | 1,200 |
| Third-party email delivery API built into the product | 800 |
Allocation bases agreed for the quarter:
- Cloud tags show 80% of hosting is production; 20% is development and test.
- The DevOps team spends 50% of its time keeping production running and 50% building new infrastructure features.
Step 1: build cost of sales
| Cost of sales line | Workings | Subscription £ | Services £ |
|---|---|---|---|
| Production hosting | 15,000 × 80% | 12,000 | |
| DevOps running production | 16,000 × 50% | 8,000 | |
| Support team | 100% | 7,500 | |
| Payment processing fees | 100% | 1,200 | |
| Email delivery API | 100% | 800 | |
| Implementation consultant | 100% | 4,500 | |
| Total | 29,500 | 4,500 |
Total cost of sales = 29,500 + 4,500 = £34,000.
Step 2: calculate the margins
| Margin | Revenue £ | Cost of sales £ | Gross profit £ | Gross margin |
|---|---|---|---|---|
| Subscription | 88,500 | 29,500 | 59,000 | 66.7% |
| Professional services | 6,000 | 4,500 | 1,500 | 25.0% |
| Total | 94,500 | 34,000 | 60,500 | 64.0% |
Workings: 59,000 ÷ 88,500 = 66.7%; 1,500 ÷ 6,000 = 25.0%; 60,500 ÷ 94,500 = 64.0%.
A subscription margin in the mid-60s is on the low side for SaaS, where many companies report somewhere around 70% to 80%, though it varies widely by product and stage. The table makes the drivers easy to see: hosting and DevOps together are £20,000, or 22.6% of subscription revenue.
Step 3: the reclassification journal
The hosting invoice was posted in full to an R&D hosting account, and DevOps salaries sit in R&D payroll. The monthly reclassification moves the cost-of-sales share across:
| Account | Dr | Cr |
|---|---|---|
| Cost of sales: hosting | £12,000 | |
| R&D: hosting | £12,000 | |
| Cost of sales: DevOps staff costs | £8,000 | |
| R&D: staff costs | £8,000 |
The journal has no effect on profit, only on where costs appear. Attach the cloud tag report and the agreed time split as support.
What a mis-mapping does
Suppose the whole £15,000 hosting invoice had gone to cost of sales and DevOps had been left entirely in R&D. Subscription cost of sales would be 15,000 + 7,500 + 1,200 + 800 = £24,500, and subscription gross margin would be (88,500 − 24,500) ÷ 88,500 = 72.3%. That's 5.6 percentage points higher than the policy-based figure, from two mapping decisions. This is why investors ask how gross margin is built.
If you report under US GAAP (ASC 606)
US GAAP doesn't define cost of revenue for software either, and the presentation choices are similar. US-listed SaaS companies typically present "cost of revenue" split between subscription and professional services, and SEC reporting means non-GAAP "adjusted gross margin" figures need reconciling to the reported numbers. Software development cost rules differ between US GAAP and IFRS, which can change how much amortisation exists to classify in the first place.
Common mistakes and audit watch-outs
- All hosting in cost of sales. Development and test environments are R&D. Without cloud tags, the split is a guess.
- No documented allocation basis. A percentage nobody can explain won't survive due diligence.
- Bases never refreshed. Teams change. An allocation from two years ago is probably wrong now.
- Changing the policy mid-year without restating. Trends become meaningless. Restate comparatives or show the effect.
- Blended margin only. A growing services business can drag the total margin down and hide what's happening in subscriptions.
- AI-suggested remapping applied in bulk. AI can spot accounts that look out of place, but a remap changes reported margins. Each change needs a person's approval and a note in the policy.
Tools that can help
Tracking categories in Xero, classes in QuickBooks or departments in NetSuite let you tag costs by function as they're posted, which cuts down month-end reclassifications. Cloud providers' own cost tagging tools make the production vs development split visible. Reporting tools such as Fathom or Syft present gross margin trends, and Excel or Google Sheets work well for the allocation workings. None of them decide the policy; they make it quicker to apply.
Take it to your boss: one slide
Making our gross margin defensible
The problem: our gross margin depends on mapping and allocation choices that aren't written down, so it could move a long way under investor or auditor questions.
Three changes
- Write a one-page cost of sales policy covering hosting, people, payment fees and amortisation.
- Tag cloud costs by environment so the production share is measured, not estimated.
- Report subscription and services margin separately, with a monthly reclassification journal and quarterly review of allocation bases.
| Risk | Control |
|---|---|
| Margin overstated by mis-mapped costs | Approved policy and annual chart of accounts mapping review |
| Out-of-date allocations | Quarterly sign-off of time splits by department heads |
| Inconsistent trends | Restate comparatives when the policy changes |
| AI remapping errors | AI flags only; every remap approved and logged |
How we'll measure it: share of hosting cost covered by tags, number of unmapped accounts (target zero), and month-on-month margin movements explained.
Key takeaways
- Gross margin % = (Revenue − Cost of sales) ÷ Revenue × 100, but what goes in cost of sales is a policy choice.
- Production hosting, support, DevOps running production, embedded third-party software and service delivery staff are the usual core.
- Many teams report subscription and services gross margin separately, so one doesn't hide the other.
- Written allocation bases, refreshed regularly, are what make the number defensible.
- A couple of mapping choices can move margin by several points, so expect questions and keep the workings.
FAQs
What's a good gross margin for SaaS?
Many SaaS businesses report subscription gross margins somewhere between 70% and 80%, but it depends heavily on the product, hosting intensity and stage. Comparisons only work if you know how the other company defines cost of sales.
Should customer success be in cost of sales?
It depends on what the team does. A common approach is to put onboarding and ongoing service in cost of sales, and renewal and upsell activity in sales and marketing, split by a documented time estimate.
Do share option charges go in cost of sales?
When the P&L is presented by function, the share-based payment charge (under IFRS 2 or FRS 102 Section 26) is typically allocated to the function the employee works in, so the charge for support staff usually lands in cost of sales. Some companies also show an adjusted margin excluding it.
Can AI work out our allocations?
It can help gather evidence: summarising time-tracking data, reading cloud cost reports by tag, or flagging accounts that look misclassified. The allocation bases themselves are agreed by people and signed off by the department heads concerned.
Related guides
- Cloud Hosting Costs: Accruing, Allocating, and COGS vs Opex
- Capitalising Software Development Costs: When and How
- SaaS Metrics Formula Sheet (CAC Payback, LTV, Magic Number, Rule of 40)
- Monthly Management Accounts and Board Pack Layout
More in Metrics and Reporting guides.
From the Club
Gross margin: high. Coffee margin: tight. The Team Mug · The Triple Tick Bag
Join the Club. New guides, early access and members-only batches. Join here.
This guide is general information about common practice. It isn't tailored to any business, and standards, tax rules and figures change. Check your own circumstances, the latest rules and, where needed, a qualified professional before acting.
Last reviewed: October 2026.