Multi-Tenant SaaS diagram template

Shared application tier with tenant routing, isolation and per-tenant limits.

Multi-Tenant SaaS architecture diagramOpen in ArchBoard

Builds a new scene in your browser. Your existing scenes are not touched.

About this design

A SaaS product serves many customers from one codebase, and the central decision is how strictly their data is separated. This template uses a shared application tier that resolves the tenant from the hostname or token on every request and carries it through the whole call. A tenant router sends small customers to a pooled database where each row carries a tenant id enforced by row level security, while a large or regulated customer is routed to a dedicated database. Per-tenant rate limits and quotas stop one noisy neighbour from degrading everyone else, and usage events feed billing. Use the diagram to discuss the isolation spectrum from shared schema to separate databases, onboarding automation, per-tenant backups and restores, data residency, and the failure mode where a missing tenant filter exposes one customer's data to another.

Diagram as text

This is the source of the diagram, in the ArchBoard diagram DSL. Paste it into Tools, Diagram from text to rebuild or change it.

title "Multi-tenant SaaS"
direction LR
user "Tenant users" -> gateway "API gateway" -> ratelimiter quota "Per-tenant limits"
gateway -> service app "Application"
[app x3]
app -> service router "Tenant router"
router -> db postgres "Pooled database"
router -> db postgres "Dedicated database"
app -> topic kafka "Usage events" -> worker bill "Billing meter"

Related guides

More web architecture templates