Cost

What it costs to run a SaaS, after you have built it

A row of five electricity meters on a brick wall, wired in beside each other
Photo by abdurrehman_gujjar on Unsplash

The build cost is a number you pay once and can plan around. What an MVP costs is the question every founder asks first, and it is the easier of the two — it has an end date.

The running cost does not. It arrives every month whether anyone signed up or not, it compounds with usage, and it is largely decided by architecture choices made during the build, when nobody was thinking about the bill. This is what it actually looks like.

The five lines the bill is made of

Almost every SaaS infrastructure bill decomposes into the same five categories. Knowing which one dominates yours tells you where optimisation is worth anyone's time.

LineWhat it isHow it scales
ComputeApp servers, background workers, build minutesWith traffic, and with work you left on the request path
DatabaseManaged Postgres or equivalent, plus backups and replicasWith data volume and query load — the stickiest line
Storage and egressFiles, images, backups, and bandwidth outWith what users upload, and what you serve
Third-party servicesEmail, payments, auth, search, model inferencePer message, per transaction, per token — usually per-use
ObservabilityError tracking, logs, metrics, uptimeWith log volume, which is a choice more than a consequence

The database is the line that behaves worst. Compute can be scaled down at 3am; a database holding production data cannot, it needs headroom you are paying for even when idle, and migrating it later is the most disruptive piece of work on this list.

Realistic monthly ranges at three stages

These are for a typical B2B SaaS — web application, background jobs, a relational database, no heavy video and no significant model inference. Those two change the shape entirely and are covered below. Figures are in USD, and every one of them is a range because the honest answer depends on choices you have not made yet.

StageWhat it looks likeMonthly
Pre-launchBuilt, deployed, a handful of real users$0 – $100
Early tractionHundreds to low thousands of users, real data, backups that matter$200 – $800
A real productPaying customers, staging and production, uptime commitments$1,000 – $5,000

The first row surprises people, and it should be treated as a warning rather than good news. Free tiers make the first months feel free, and the jump from the first row to the second is not gradual — it happens the week you cross a free-tier limit, and it arrives as a bill, not a notification you acted on.

The line that surprises people: egress

Bandwidth out of a cloud provider is billed, bandwidth in usually is not, and the rate is high relative to what the same traffic costs anywhere else. For a text-heavy B2B app this is a rounding error. For anything serving images, video, exports or large API responses it can quietly become the largest single line.

It is also the line with the largest spread between providers. Object storage with no egress fees — Cloudflare R2 built its pitch on exactly this — versus per-gigabyte egress on a traditional provider is a difference of orders of magnitude at volume, for storage that is otherwise interchangeable. Check AWS's own pricing page for the comparison rather than taking anyone's summary of it, including this one.

The practical advice: find out today which line dominates your bill. Most teams have never looked, and are optimising the one they assume rather than the one they are paying for.

A water drop forming on the end of a tap in the dark
Nothing on the leak list is dramatic. Each one is a few tens of dollars a month that nobody is accountable for, which is exactly why they survive for years.Photo by mikiesharma on Unsplash

The line that grows fastest: inference

If your product calls a language model, that line behaves unlike everything else in a SaaS cost base. It is genuinely variable — it scales with usage rather than with users — so a single enthusiastic customer can cost more than a hundred ordinary ones, and your gross margin becomes a function of how people use the feature.

Rates are published by the vendors — OpenAI and Anthropic both list them — and they have fallen repeatedly, so build the estimate from your own token counts rather than from a figure you read once. What a RAG chatbot costs has the arithmetic worked through end to end.

Two controls matter more than model choice: a hard per-account cap so no single user can run up an unbounded bill, and caching of anything asked repeatedly. Both are cheap to add during the build and awkward to retrofit once usage patterns exist.

Where the money actually leaks

In most audits we run, a meaningful share of the bill is paying for nothing at all. The list is boring and it is always roughly the same:

  • Staging environments running 24/7. They are used during working hours in one timezone and billed for all of them. Scheduling them off outside those hours is an afternoon of work.
  • A database provisioned for a spike that never came. Over-provisioning is prudent once and then never revisited. Check actual utilisation against what you are paying for.
  • Log retention nobody chose. Default retention on a verbose application can cost more than the compute generating it. Decide how far back you genuinely need to search, which is usually weeks rather than a year.
  • Environments from abandoned work. A preview deploy, a proof of concept, a migration that was cancelled. These outlive the people who created them.
  • Seats on tools for people who left. Not infrastructure, but it sits on the same monthly statement and the same nobody owns it.
  • Orphaned storage. Snapshots, old backups and build artefacts accumulate silently because nothing ever deletes them.

None of this is clever engineering. It is an hour with the billing console once a quarter, and it is consistently the highest return per hour available in a cost exercise.

The rule of thumb that survives contact

For a healthy B2B SaaS, infrastructure should be a modest fraction of revenue — public SaaS companies typically report gross margins in the 70–80% range, and the hosting bill is one component of the remainder. If your infrastructure cost is climbing towards a third of revenue, the problem is a pricing or architecture problem, not a procurement one.

That distinction matters because the two have different fixes. A procurement problem is solved with reserved instances and a negotiated contract. An architecture problem — synchronous work that should be queued, queries that scan tables, a design that requires vertical scaling — is solved by changing the system, and the a16z analysis of cloud costs at scale is the well-known argument that this compounds as a company grows.

Our own experience is narrower and points the same way: when a bill is growing faster than usage, the cause is nearly always on the why is my app slow list. Work on the request path that should be a background job, or a query pattern that makes you buy a bigger database every six months.

What this means before you build

Most of the running cost is committed during the build, by people optimising for shipping rather than for the bill. That is usually the correct trade — an MVP that ships late to save $80 a month is a bad trade — but a few decisions are worth making deliberately because they are expensive to reverse:

  1. Where the database lives, and whether you can move it later without downtime.
  2. Whether heavy work is on the request path or behind a queue. This decides your compute bill more than instance size does.
  3. Where files are stored, and what egress costs from there.
  4. Whether per-use services have caps, so a bug or a heavy user cannot produce an unbounded invoice.
  5. Whether you can actually see per-feature cost, or only one total. You cannot price a feature whose cost you cannot isolate.

The last one gets skipped almost universally and is the one that hurts at the point you want to introduce usage-based pricing.

What we do

Every MVP build we ship includes the deployment, the monitoring and a stack whose running cost we can state before you commit to it — the figure belongs in the conversation before the build, not in a surprise the month after launch. You own the accounts from the first commit, so the bill is yours and visible, never resold through us.

Where a bill is already out of proportion to usage, that is a scale and re-architecture question rather than a vendor one, and it usually resolves to two or three specific changes. Why MVPs break at scale covers the pattern behind most of them.

Frequently asked questions

How much does it cost to run a SaaS per month?

For a typical B2B SaaS without heavy video or model inference: roughly $0–$100 a month pre-launch, $200–$800 with early traction and real data, and $1,000–$5,000 once there are paying customers, a staging environment and uptime commitments. The database and compute dominate. Model inference and media streaming change the shape entirely and should be estimated separately.

What are the main infrastructure costs for a SaaS?

Five lines: compute (app servers, background workers, build minutes), the database with its backups and replicas, storage plus egress bandwidth, third-party per-use services like email, payments and model inference, and observability. The database is the stickiest — it needs headroom you pay for while idle and is the most disruptive component to migrate later.

Why did my cloud bill suddenly jump?

Most often you crossed a free-tier or included-usage threshold, which arrives as a bill rather than a warning. Other common causes are egress from serving files or large API responses, default log retention on a verbose application, a staging environment left running, or a per-use service without a cap where one heavy user or a retry loop ran up usage.

What percentage of revenue should infrastructure cost be?

A modest fraction. Public SaaS companies typically report gross margins in the 70–80% range, with hosting one component of the remainder. If infrastructure is heading towards a third of revenue, treat it as a pricing or architecture problem rather than a procurement one — reserved instances will not fix a design that requires a bigger database every six months.

How can we reduce our SaaS hosting costs?

Start by finding out which of the five lines actually dominates, because most teams optimise the one they assume. Then clear the routine waste: staging environments running outside working hours, over-provisioned databases nobody revisited, default log retention, environments left from abandoned work, and orphaned snapshots and backups. An hour with the billing console each quarter is the highest return per hour in this exercise.

References

  1. R2 pricingCloudflare
  2. Amazon S3 pricingAmazon Web Services
  3. API pricingOpenAI
  4. PricingAnthropic
  5. The Cost of Cloud, a Trillion Dollar ParadoxAndreessen Horowitz

Keep reading

Hands working through figures on a desk calculator
MVP

MVP Development Cost in 2026

Most MVP quotes are wrong for the same reason: they price a feature list instead of a decision. Here are the real ranges and what actually moves them.

The ChatGPT app open on a phone screen
AI

How Much Does a RAG Chatbot Cost?

A demo costs a weekend. A version you can put in front of customers costs considerably more, and almost none of the difference is the model.

An aerial view of a motorway backed up with traffic
Scale

Why MVPs Break Under Real Load

Success is the failure mode. The shortcuts that got you to launch are exactly the ones that break when launch works.

Let's put it into production.

Book a 30-minute call — you'll walk away with a scope, a timeline and a fixed price.

Book a call