SaaS Gross Margin Calculator
Enter revenue, hosting and support costs to find your SaaS gross margin.
Result
How it is calculated
Enter revenue, hosting cost and support cost for the same period (a month, a quarter or a year). The tool treats cost of goods sold as just those two costs: COGS = hosting + support. Then gross profit = revenue − COGS and gross margin = gross profit / revenue × 100. The margin is shown as a percentage with two decimals and the two money values in dollars. Revenue must be above zero; hosting and support can be zero. Nothing stops the margin from going negative: if COGS exceeds revenue you get a negative profit and margin, for instance $1,000 revenue with $1,300 of costs gives −30.00%. Costs outside those two fields, such as payment-processing fees, third-party licences or onboarding staff, must be added into one of them by you.
Worked example
A SaaS product brings in $50,000 in a month. Hosting costs $7,500 and support costs $6,000. COGS: 7,500 + 6,000 = 13,500, shown as $13,500.00. Gross profit: 50,000 − 13,500 = 36,500, shown as $36,500.00. Gross margin: 36,500 / 50,000 × 100 = 73, displayed as 73.00%. Each dollar of revenue leaves 73 cents to cover sales, marketing and development.
Common mistakes
- Mixing periods, such as monthly revenue with annual hosting bills. The margin is only meaningful when all three figures cover the same period.
- Putting sales, marketing or R&D salaries into the support field. Gross margin is meant to exclude those operating expenses, so including them gives an artificially low margin.
- Leaving out costs that really belong in COGS, such as payment-processing fees or paid third-party APIs. With only hosting and support counted, the margin looks better than it is unless you fold them in.
- Using bookings or invoiced amounts instead of recognised revenue for the period, for example an annual contract paid up front in a single month.
- Confusing margin with markup. A 73% margin means profit is 73% of revenue; it is not 73% on top of cost.
Sources
- 5.1 The Income Statement (Principles of Finance) — OpenStax, Rice University
About this calculator
Gross margin for a SaaS company measures how much revenue is left after subtracting the cost of goods sold (COGS) — for software, this is primarily hosting/infrastructure costs and customer support costs, rather than the manufacturing costs a physical-goods business would have. It's expressed as a percentage of revenue and is one of the most closely watched metrics in software business models, because it reveals how efficiently the underlying product itself can be delivered at scale, before accounting for sales, marketing, and R&D spend.
This calculator computes SaaS gross margin and gross profit from revenue, hosting cost, and support cost. It's a standard metric for SaaS founders, finance teams, and investors — public SaaS companies often target gross margins of 70–80%+ — used to benchmark unit economics, evaluate infrastructure efficiency, and assess a company's health during fundraising or board reporting.
Was this helpful?
You can pick up to 3 reactions.
Popular calculators
Loan Calculator
Monthly payment, total interest and full amortization schedule.
Percentage Calculator
Percent change, percent of, and ratio calculations.
Discount Calculator
Calculate final price, savings, and discount amount.
BMI Calculator
Body mass index from height and weight (metric or imperial).
Age Calculator
Compute your exact age in years, months and days from a birth date.
Compound Interest Calculator
Calculate the final amount and interest earned with compounding.
All Calculators
- Loan Calculator
- Profit Calculator
- Discount Calculator
- BMI Calculator
- Percentage Calculator
- Ideal Weight Calculator
- Age Calculator
- Pregnancy Due Date Calculator
- Compound Interest Calculator
- BMR Calculator (Basal Metabolic Rate)
- Tip Calculator
- Fuel Cost Calculator
- Date Difference Calculator
- Sleep Cycle Calculator
- Daily Water Intake Calculator
- Simple Interest Calculator
- Heart Rate Zones Calculator
- Running Pace Calculator
- Pet Age Calculator
- Calories Burned Calculator
- Macro Calculator
- TDEE Calculator (Total Daily Energy Expenditure)
- Waist-to-Hip Ratio Calculator
- Honor Roll Calculator
- One Rep Max (1RM) Calculator
- Ovulation Calculator
- Electricity Cost Calculator
- Unit Price Calculator
- Savings Goal Calculator
- Break-Even Point Calculator
- Paint Calculator
- Course Grade Average Calculator
- Business Days Calculator
- Time Duration Calculator
- Fuel Economy Calculator
- Temperature Converter
- Tile Calculator
- Aspect Ratio Calculator
- Roman Numeral Converter
- Goal Weight Timeline Calculator
- Salary Converter (Hourly to Annual)
- Credit Card Validator (Luhn)
- Body Surface Area (BSA) Calculator
- Feels-Like Temperature Calculator
- Ohm’s Law Calculator
- PPI (Pixel Density) Calculator
- Molar Mass Calculator
- Zodiac Sign Calculator (Western + Chinese)
- IBAN Validator
- Shoe Size Converter
- Country Info & Dialing Code Lookup
- Time Zone Difference (World Clock)
- CAGR (Compound Annual Growth Rate) Calculator
- Rule of 72 Calculator
- Blood Alcohol Content (BAC) Calculator
- Lean Body Mass (LBM) Calculator
- Pythagorean Theorem Calculator
- Speed Converter
- Download Time Calculator
- Date Calculator (Add/Subtract)
No calculators found
Comments (1)
Use revenue recognised in the period, not cash billed. An annual plan paid up front would otherwise make one month look far better than the rest, while the costs stay spread out. Payment fees, third-party API charges and customer-success staff belong in the cost boxes too, because the tool only subtracts hosting and support. Negative margins are shown as they are. Which costs do you count toward your cost of revenue?