Engineering · Architecture
From one server per client to one platform: notes on going multi-tenant
What changes when a SaaS product moves from a dedicated server for every client to one shared multi-tenant platform, and the decisions that matter most.
By Yosef Worku · November 2026 · 2 min read
Many SaaS products start with one server per client. Each new customer gets a copy of the application and a database of their own. It is simple, it keeps data apart, and it works well for the first handful of clients.
Then it stops working. We have designed and led this move on a production platform, and these are the notes we would hand to a team about to do the same.
Why one server per client runs out
Every new client means setting up a machine by hand, so onboarding takes days. Each server sits idle for most of the day and is busy for an hour. Every security patch, every deploy and every backup is multiplied by the number of clients.
The work grows in step with sales, and good software should do the opposite.
Decide how tenants are kept apart
Everything else hangs on this decision. There are three usual options:
- A shared database with a tenant column. The cheapest to run. One missed filter in one query leaks data between clients.
- A schema per tenant. A middle path, with more moving parts when the schema changes.
- A database per tenant. Strong isolation, and easy backup, export and deletion for a single client. There are more connections to manage.
We chose a database per tenant. The clients handled financial data, and “your data lives in its own database” is a sentence a customer understands and an auditor can check.
Route every request to its tenant early
Each client gets a subdomain. A small piece of middleware reads the host name, looks the tenant up, and attaches the right database connection to the request before any business code runs.
Handlers never pick a database themselves, so they cannot pick the wrong one. The tenant lookup is cached for a short time, because it happens on every request.
Pool connections, and put a ceiling on the pool
A database per tenant means many connections. Opening one for every request is slow, and keeping all of them open for ever is wasteful.
A pool that keeps recently used connections and closes the ones used least recently handles both. Set the ceiling from real traffic, never from a guess.
Stop one tenant from starving the others
On a shared platform, one client’s heavy job can slow everybody down. Background work needs limits per tenant: how many jobs run at once, and how fast they may call outside services. The same goes for API rate limits.
Fairness has to be built in. It does not happen by accident.
Move one tenant at a time
Do not move everyone in one night. Move each client separately, with a rehearsal, a check of their data on the new platform and a way back. The first move teaches you the most, so pick a small and friendly client for it.
What you get at the end
Onboarding a client becomes a few minutes of configuration. There is one system to patch, monitor and back up. The cost of serving one more client drops close to zero, and that is what makes a SaaS business work.
If you are facing this move, or starting a platform and want to avoid it, talk to us.