$
MRRdeals
Free tool · no signup

Profit margin calculator

Enter your revenue and costs for a month (or a year) to get gross margin, net margin and markup instantly.

Results

Gross margin
Gross profit $8,500
85.0%
Net profit margin
Net profit $5,500
55.0%
Markup on costs
Net profit ÷ total costs
122.2%
Total costs
$4,500

Profit margin formulas

  • Gross profit = revenue − cost of goods sold
  • Gross margin = gross profit ÷ revenue × 100
  • Net profit = gross profit − operating expenses
  • Net profit margin = net profit ÷ revenue × 100
  • Markup = net profit ÷ total costs × 100

What goes where for a SaaS

Cost of goods soldOperating expenses
Hosting, database, CDNMarketing and ads
Per-use APIs (AI models, SMS, email sending)Tools (analytics, CRM, design)
Payment fees, app store commissionsContractors, salaries
Customer support directly tied to deliveryLegal, accounting, domains

Example

A SaaS makes $10,000 a month. Hosting, APIs and Stripe fees cost $1,500, and tools, ads and a part-time contractor $3,000. Gross margin is 85%, net margin 55%, and the business keeps $5,500 a month.

Margins of SaaS for sale

Among the 896 verified-revenue listings on TrustMRR we score, the median stated profit margin is 85% (middle half: 70%–95%). Margins are self-reported by sellers, so buyers recompute them from invoices during due diligence: see our SaaS due diligence checklist. Margin also drives what a business is worth: try the payback calculator or the valuation calculator.

Frequently asked questions

How do you calculate profit margin?

Profit margin = profit ÷ revenue × 100. Gross margin uses revenue minus the direct cost of delivering the product; net margin subtracts every expense. $10,000 of revenue and $4,500 of total costs give a 55% net profit margin.

What is the difference between margin and markup?

Margin divides profit by revenue; markup divides profit by costs. The same $5,500 profit on $10,000 of revenue and $4,500 of costs is a 55% margin but a 122% markup.

What is a good profit margin for a SaaS?

Software usually has 70-90% gross margins. On TrustMRR, the median small SaaS for sale claims an 85% profit margin, with the middle half between 70% and 95%. AI products paying per API call often land much lower.

Should payment fees count in gross margin?

Yes. Payment processing (Stripe fees, app store commissions of 15-30%), hosting and per-use APIs are direct costs of delivering the product and belong in cost of goods sold.

More free tools