Multi-tenant SaaS architecture lets a software provider serve multiple customers through a common service while keeping each customer’s data and access separate. The business benefit is the potential to share infrastructure and operations; the engineering challenge is making that sharing safe, reliable and economically worthwhile.
For buyers and product teams, the key decision is not simply whether to use multitenancy. It is which components to share, which to dedicate, and how to prove that tenant boundaries work.
What is a tenant in SaaS?
A tenant is a customer or group whose data, users and settings are managed as a distinct unit. In business software, one organization might be one tenant, but a company could also need separate tenants for divisions, regions or development environments. A tenant can have many users, and a user may need access to more than one tenant.
Define that boundary early: it affects permissions, reporting, data location, billing and offboarding. Microsoft’s guidance on tenancy models recommends starting with the customer relationship and business requirements rather than choosing infrastructure first.
Three common architecture choices
Shared application and shared database
Customers use the same application and database infrastructure. Tenant identifiers and enforced access policies separate their records. This can lower infrastructure and maintenance costs, but makes isolation, workload management and tenant-specific recovery especially important. A single faulty release may also affect many customers.
Shared application with a database per tenant
The application is shared, while each tenant has its own database. This can make tenant-specific backup, restore and data placement easier to arrange, but database provisioning, updates and routing add operational work. Separate databases do not automatically isolate shared application servers or other shared services.
Dedicated deployment or a hybrid
A provider can dedicate an application stack to a tenant, or combine dedicated and shared components. Dedicated resources can reduce some cross-tenant performance and data risks, but usually increase infrastructure and management costs. A hybrid might place most customers on shared infrastructure while giving a customer with specific requirements a dedicated deployment. Microsoft compares these models and notes that the right balance depends on scale, automation, service expectations and customer requirements.
How tenant isolation works in practice
Signing in successfully is not enough. The service must determine which tenant a user is allowed to act for, establish that context from a trusted source, and enforce it wherever tenant resources are accessed. AWS distinguishes tenant isolation from authentication and general authorization.
- Identity and permissions: verify membership and role for the selected tenant on each relevant request; do not trust a customer-supplied tenant ID by itself.
- Data access: enforce tenant-aware rules in application queries and, where appropriate, at the database layer. In PostgreSQL, row-level security can add a safeguard, but privileged roles and table owners may bypass it unless configured appropriately. Test with the actual application roles. See PostgreSQL’s row security documentation.
- Beyond the database: protect files, search indexes, background jobs, exports and caches too. Tenant-scoped cache keys help prevent collisions, but access controls are still needed.
- Verification: automate tests that attempt cross-tenant reads and writes, including after a user switches tenants, permissions change or a pooled connection is reused.
These controls reduce risk; they are not a guarantee of security or regulatory compliance. Isolation requirements and evidence should be agreed for the particular product and customers.
Plan for performance, recovery and cost
A busy tenant can consume shared capacity and slow others down—the “noisy neighbor” problem. Measure usage and latency by tenant where feasible, test realistic peak loads, and consider quotas, rate limits or workload separation. Dedicated databases can help with database contention, but they do not remove bottlenecks in shared application components.
Recovery deserves a design of its own. A backup of a shared database does not necessarily provide a simple way to restore one customer’s records without affecting others. Define recovery objectives, test tenant-level export and restoration, and document retention and deletion. Microsoft’s storage guidance describes the trade-offs between shared and dedicated data resources.
For commercial planning, estimate infrastructure, support, monitoring and engineering costs under both typical and high-usage scenarios. Shared infrastructure may be cheaper per customer, but savings depend on utilization and the controls required. Allocate shared costs consistently before using tenant-level profitability estimates to inform pricing or investment decisions.
Questions to ask a delivery or strategic partner
- Which components are shared, and which are dedicated? How are tenants mapped to them?
- How is tenant context established and enforced across APIs, databases, files and background processing? What isolation tests can be demonstrated?
- How are usage limits, service objectives, incidents and customer communications handled?
- Can one tenant’s data be exported, restored, moved or deleted? What has been tested?
- Where can data and backups be stored, and which providers or subcontractors are involved?
- Who owns the code, infrastructure, operating responsibilities and handover documentation? How would the parties manage changes or end the engagement?
Choose the boundary before the technology
There is no universally best multi-tenant model. Start with customer isolation and recovery needs, expected workloads and a cost model; then test the simplest architecture that meets them. As a software development and technology consulting company, Altweeb can be part of a conversation about these delivery choices alongside the product owner and other partners.
To explore this further, see Software & Digital Product Development.
Add your perspective