Modern SaaS Is an Ecosystem, Not Just an Application
A web application can look deceptively simple from the outside: a browser talks to an API, the API talks to a database, and somewhere in the middle the useful work happens. That model is still technically true, but for a serious modern SaaS platform it is nowhere near complete.
Once security, identity, realtime communication, asynchronous processing, CI/CD, observability, customer support, analytics, external services, multiple hosting models and now AI are taken into account, the “application” becomes only one component in a much larger technology ecosystem.

The diagram above is an attempt to represent that ecosystem as a complete reference architecture. It is deliberately broad: not every SaaS product needs every component, but almost every mature SaaS platform will eventually encounter most of these architectural concerns in one form or another.
The application is only one layer
At the centre is the part we traditionally think of as the application:
- the front-end UI;
- backend services and APIs;
- business logic;
- product modules;
- tenant management;
- configuration and entitlements;
- administration interfaces.
That is only Layer 7 in the reference model.
Before a request even reaches that application it may already have passed through DNS, a CDN, DDoS protection, a WAF, bot protection, a load balancer, TLS termination, identity services, JWT validation, API rate limiting, request-schema validation and a reverse proxy.
After the application performs its work, it may interact with databases, caches, queues, event streams, object storage, external APIs, analytics systems, email providers, observability platforms and support systems.
Meanwhile, an entirely separate delivery system is responsible for getting the code into production safely.
A simplified view looks something like this:
flowchart LR
U["Users & Clients"] --> E["Edge & Network Security"]
E --> I["Identity & Access"]
I --> A["API Security"]
A --> C["Client / API Communication"]
C --> W["Web Server / Reverse Proxy"]
W --> APP["Application Services"]
APP --> D["Data"]
APP --> M["Messaging & Async"]
APP --> R["Realtime Services"]
APP --> X["External Integrations"]
CI["CI/CD & Release Engineering"] --> APP
APP --> O["Observability & Incident Management"]
APP --> P["Ancillary Operational Services"]
G["Governance & Compliance"] -.-> APP
G -.-> D
G -.-> CI
G -.-> O
The important point is not the exact placement of every box. It is that the application sits inside an operating system of services around it.
Sixteen architectural layers
The reference model breaks the ecosystem into sixteen main areas.
1. Users and client access
Modern SaaS rarely means only “a website.”
Clients may include:
- web browsers;
- iOS and Android applications;
- desktop applications;
- command-line tools;
- developer and DevOps tooling;
- API and SDK consumers;
- tenant administrators;
- B2B partners and resellers.
Those clients may themselves be implemented using React, Next.js, Angular, Vue, Swift, Kotlin, Flutter, React Native, Electron, Tauri or other technologies.
Immediately, one product can have several distinct client architectures.
2. Edge and network security
Before application code sees a request, an edge layer may handle:
- DNS;
- CDN delivery;
- WAF rules;
- DDoS protection;
- bot mitigation;
- traffic filtering;
- load balancing;
- TLS certificates;
- geographic and IP restrictions.
Cloudflare, AWS, Azure, Google Cloud, Fastly and Akamai can provide overlapping parts of this layer.
This is one of the first places where modern architecture becomes less about writing code and more about composing capabilities.
3. Identity and access management
Authentication has grown far beyond a login form.
A serious SaaS platform may need:
- SSO;
- SAML;
- OpenID Connect;
- OAuth;
- MFA;
- WebAuthn;
- JWT access tokens;
- refresh tokens;
- token rotation and revocation;
- SCIM provisioning;
- RBAC;
- fine-grained permissions;
- session management;
- access auditing.
An enterprise customer may consider SSO, SCIM, RBAC and audit logs basic requirements rather than optional extras.
4. API security and request processing
An authenticated request is not automatically a safe request.
The API layer may need to perform:
- endpoint-specific rate limiting;
- JWT validation;
- JSON schema validation;
- required and allowed field checking;
- numeric and string range checking;
- query/path/header validation;
- payload-size restrictions;
- MIME-type validation;
- upload controls;
- injection protection;
- SSRF protection;
- idempotency;
- replay protection;
- correlation IDs;
- safe response handling.
This layer can involve both application code and dedicated API-security products such as Cloudflare API Shield, Kong, 42Crunch, Wallarm, Salt Security or similar platforms.
5. Client-to-API communication
REST is only one communication mechanism.
Applications increasingly combine:
- REST;
- GraphQL;
- WebSockets;
- Server-Sent Events;
- gRPC;
- gRPC-Web;
- webhooks;
- occasionally WebRTC or long polling.
A normal request/response API, a live collaboration session and an AI response being streamed token by token have very different communication characteristics.
6. Web servers and reverse proxies
There is often another layer between the network and application runtime:
- NGINX;
- Apache;
- Caddy;
- Traefik;
- IIS;
- Envoy.
These can deal with routing, caching, compression, TLS termination, static content and application hand-off.
Behind them may sit Node.js, Kestrel, Spring, Tomcat, Gunicorn, Uvicorn, Go, PHP-FPM or another runtime.
The once-simple phrase “web server” now covers several quite different responsibilities.
7. The application itself
Only now do we reach the product’s actual business services.
This may contain:
- front-end applications;
- backend services;
- BFFs for web or mobile;
- domain services;
- tenant management;
- administration;
- feature flags;
- configuration;
- subscription entitlements;
- notifications;
- business rules.
This is the part users normally perceive as “the product.”
Everything else exists partly to make this layer secure, reliable, scalable, supportable and commercially viable.
8. Realtime communication
Realtime features introduce another architectural category.
Examples include:
- WebSocket gateways;
- SSE streams;
- user presence;
- collaborative editing;
- live notifications;
- AI streaming;
- job-progress updates;
- cross-node realtime distribution.
Once an application runs on multiple server instances, realtime messaging must usually be distributed through something such as Redis, NATS or Kafka rather than relying on one process’s memory.
9. Messaging, events and asynchronous processing
Some work should not happen inside an HTTP request.
Modern platforms often rely on:
- RabbitMQ;
- SQS;
- Azure Service Bus;
- Kafka;
- Redpanda;
- Kinesis;
- NATS;
- EventBridge;
- BullMQ;
- Celery;
- Sidekiq;
- worker processes;
- schedulers;
- dead-letter queues.
Then there are the less glamorous but essential concerns:
- retries;
- backoff;
- duplicate handling;
- idempotent consumers;
- poison messages;
- event-version compatibility.
Asynchronous architecture solves one class of problems while introducing an entirely new class of operational complexity.
10. The data layer is no longer “the database”
A modern data layer may contain several specialised stores:
- PostgreSQL or MySQL for relational data;
- MongoDB or DynamoDB for document/NoSQL workloads;
- Redis for caching;
- S3 or equivalent object storage;
- OpenSearch or Elasticsearch for search;
- Snowflake, BigQuery or Redshift for analytics;
- vector databases such as pgvector, Pinecone, Weaviate, Qdrant or Milvus;
- backup and archival systems.
Data lifecycle then adds:
- retention;
- deletion;
- residency;
- legal hold;
- export;
- encryption;
- tenant isolation.
AI adds another reason to think about data architecture carefully because embeddings, semantic search and RAG knowledge stores create additional representations of information that also need governance.
11. CI/CD and release engineering
The development process itself has become part of the production architecture.
Source repositories may live in:
- GitHub;
- GitLab;
- Bitbucket;
- Azure Repos.
From there a release can pass through:
- build pipelines;
- automated tests;
- dependency scanning;
- secret scanning;
- SAST and DAST;
- container scanning;
- artifact registries;
- deployment pipelines;
- DEV, TEST, STAGING and PROD environments;
- infrastructure as code;
- database migrations;
- smoke tests;
- release gates;
- blue/green deployments;
- canary releases;
- rollback;
- release notes.
A modern deployment is not ideally “build something and copy it to a server.” It is a controlled progression of an immutable change through a chain of validation and increasingly production-like environments.
12. External integrations
Most SaaS products depend on other SaaS products.
Typical examples include:
- Stripe for payments;
- Resend, SendGrid, Postmark, Mailgun or SES for email;
- Auth0, Okta or Entra for identity;
- Salesforce or HubSpot for CRM;
- GitHub, GitLab, Jira and Slack;
- OpenAI, Anthropic or other AI providers;
- incoming and outgoing webhooks.
This creates a significant architectural reality: part of your application’s behaviour lives outside your application.
A provider outage, API change, rate limit or authentication problem can become your outage even while every service you operate is healthy.
13. Ancillary platform and operational services
This is one of the easiest parts of a SaaS architecture to overlook because these tools often do not participate directly in normal application requests.
They nevertheless form a large part of the operating ecosystem.
Email and notifications
Examples include:
- Resend;
- SendGrid;
- Mailgun;
- Postmark;
- Amazon SES;
- Twilio;
- Firebase Cloud Messaging.
Without them, features such as account verification, password recovery, notifications and operational alerts may stop working.
Engineering and operations communication
Teams may rely on:
- Slack;
- Microsoft Teams;
- Discord;
- Mattermost;
- Google Chat;
- webhook-driven channels.
These can become the nervous system connecting development, deployment, support and NOC operations.
Incident and on-call systems
Examples include:
- PagerDuty;
- Opsgenie;
- Better Stack;
- Splunk On-Call;
- Jira incident workflows.
Monitoring only tells you something is wrong. Somebody still has to be told, respond, coordinate and eventually close the incident.
Error tracking and application performance
Platforms such as:
- Sentry;
- Rollbar;
- Bugsnag;
- Datadog;
- New Relic
provide visibility into what the application is actually doing in production.
Product analytics
Services such as:
- PostHog;
- Amplitude;
- Mixpanel;
- Heap;
- Google Analytics
answer a very different question:
Is the system working technically?
becomes:
Are people actually using it the way we expected?
UX and session analytics
Tools such as:
- Hotjar;
- FullStory;
- Microsoft Clarity
can expose usability problems that logs and metrics will never reveal.
A technically healthy application can still be a terrible user experience.
Customer support and feedback
A production ecosystem may additionally contain:
- Intercom;
- Zendesk;
- Freshdesk;
- Crisp;
- Help Scout;
- Canny;
- Productboard;
- UserVoice.
Support, feedback and product-development systems form another loop around the application:
flowchart LR
P["Product"] --> U["User"]
U --> A["Analytics / Session Data"]
U --> S["Support / Feedback"]
A --> T["Product Team"]
S --> T
T --> B["Backlog / Roadmap"]
B --> D["Development"]
D --> P
The product is therefore not merely deployed and left running. It lives inside a continuous feedback system.
14. Observability and incident management
Observability itself deserves a separate architecture layer.
A mature stack may combine:
- Sentry for errors;
- Prometheus for metrics;
- Grafana for dashboards;
- ELK, Loki or Splunk for logs;
- OpenTelemetry for traces;
- uptime and synthetic monitoring;
- alerting;
- incident management;
- public status pages;
- SLO and SLA measurement.
The challenge is not merely collecting telemetry.
It is correlating it.
A single user failure might involve:
- an API trace;
- three microservices;
- a queue;
- a Redis lookup;
- a database query;
- an external payment API;
- six log streams;
- two metrics alerts.
More observability data does not automatically mean more observability.
15. Business and customer systems
Commercial SaaS architecture also contains systems that have little to do with serving an HTTP request but are essential to operating the business:
- subscriptions;
- plans;
- entitlements;
- usage metering;
- invoicing;
- tax;
- dunning;
- CRM;
- ticketing;
- knowledge bases;
- customer success;
- onboarding;
- feedback;
- business analytics.
This is where software architecture and business architecture begin to overlap.
For example, a subscription tier may ultimately influence an API request:
Authenticated user
↓
Tenant
↓
Subscription
↓
Entitlements
↓
Feature / quota
↓
Application behaviour
A pricing decision can therefore become an architectural concern.
16. Governance and compliance
Finally, all of the previous layers sit inside governance constraints.
These may include:
- audit logging;
- GDPR;
- SOC 2;
- ISO 27001;
- PCI-DSS;
- HIPAA where relevant;
- data residency;
- retention;
- encryption;
- secrets management;
- KMS;
- least privilege;
- access reviews;
- vulnerability management;
- disaster recovery;
- RPO and RTO;
- privacy;
- subprocessors;
- incident response.
Importantly, compliance is not a single box that can be added at the end.
Its requirements flow through the entire architecture.
Cloud makes complexity disappear — but only operationally
One useful aspect of the architecture is that the same logical capability can be implemented in very different ways.
A queue could be:
- AWS SQS;
- Azure Service Bus;
- Google Pub/Sub;
- RabbitMQ;
- NATS.
Object storage could be:
- S3;
- Azure Blob Storage;
- Google Cloud Storage;
- MinIO;
- Ceph.
A managed cloud provider may hide database replication, hardware failure, backups or load-balancer maintenance behind a service boundary.
A self-hosted system does not eliminate those concerns. It simply transfers responsibility for them back to the organisation.
This is why the architecture should be thought of in terms of capabilities first, products second.
Self-hosting changes the responsibility boundary
If an application runs on Linux, Windows Server or private infrastructure, a team may additionally own:
- OS patching;
- host firewalls;
- runtime updates;
- certificates;
- storage;
- backup;
- failover;
- monitoring;
- capacity;
- network configuration;
- vulnerability remediation.
A managed PostgreSQL service and a PostgreSQL server running on a VM may provide similar database functionality to the application, but they represent very different operational responsibilities.
This distinction matters when judging the complexity of a system.
Then AI arrives at every layer
AI is unusual because it is not simply another isolated architecture component.
It can potentially augment almost every existing layer.
Examples include:
| Layer | Possible AI use |
|---|---|
| User experience | Chat, copilots, natural-language interfaces |
| Edge security | Bot and traffic anomaly detection |
| Identity | Risk-based authentication |
| API security | Abuse and sequence anomaly detection |
| Application | RAG, agents, summarisation, recommendation |
| Async processing | Intelligent job prioritisation |
| Data | Embeddings, semantic search, classification |
| CI/CD | Pipeline generation, test diagnosis, release-risk analysis |
| Operations | Alert correlation, incident summaries, root-cause assistance |
| Support | Ticket triage and RAG assistants |
| Product analytics | Behaviour analysis and anomaly discovery |
| Governance | Policy checks, model governance and audit assistance |
And then AI itself introduces another operating concern:
- model selection;
- prompt management;
- model gateways;
- vector stores;
- evaluations;
- guardrails;
- token usage;
- inference costs;
- model monitoring;
- model versioning;
- agent permissions;
- human approval gates.
So AI does not simplify the architecture automatically. In many cases it adds another cross-cutting architectural dimension.
Agentic systems make boundaries more important
A conventional AI assistant may produce text.
An agent can potentially do something.
That changes the risk profile dramatically.
An agent involved in deployment, for example, may need:
- credentials;
- API access;
- infrastructure visibility;
- permission to modify a system;
- monitoring feedback;
- rollback ability.
A useful agentic deployment model therefore looks less like:
AI → Production
and more like:
AI recommendation
↓
Policy evaluation
↓
Approval gate
↓
Restricted action
↓
Verification
↓
Audit trail
↓
Rollback if required
The smarter the automation becomes, the more important identity, observability, permissions and governance become around it.
The real complexity is interaction
A diagram with this many boxes can make the problem appear to be the number of technologies.
That is not quite the hardest part.
The harder problem is the number of interactions between them.
Consider something as ordinary as signing up a new customer.
A single workflow might involve:
- Cloudflare accepting the request.
- A WAF allowing it.
- The API gateway routing it.
- Request validation accepting the payload.
- The application creating the user.
- The database storing the account.
- A tenant being provisioned.
- An identity token being created.
- A background job being queued.
- Resend or SES sending verification mail.
- PostHog recording the signup event.
- Sentry recording an error if anything fails.
- Prometheus incrementing a metric.
- Grafana displaying that metric.
- Slack receiving an operational alert if failure rates rise.
- A support platform receiving a ticket if the customer cannot proceed.
Nothing about that workflow is individually extraordinary.
The complexity emerges from having to make all of it behave as one system.
Vendor sprawl creates its own architecture
There is also a point where every solved problem creates another external dependency.
A team can easily end up with:
- Cloudflare;
- AWS;
- GitHub;
- Sentry;
- Grafana;
- Prometheus;
- PostHog;
- Hotjar;
- Resend;
- Stripe;
- Slack;
- PagerDuty;
- Zendesk;
- Auth0;
- OpenAI.
Each service may be an excellent choice.
Collectively they create questions around:
- authentication;
- secrets;
- billing;
- data residency;
- access control;
- vendor outages;
- API limits;
- ownership;
- auditability;
- configuration;
- offboarding;
- cost.
That is why adding a SaaS service is still an architectural decision even when it takes five minutes to install its SDK.
Mature architecture is not the architecture with the most boxes
The reference diagram should not be interpreted as a checklist where every empty box is a failure.
A small application may have absolutely no need for Kafka, Kubernetes, SCIM, a vector database or a multi-region failover architecture.
Adding them “because enterprise systems have them” can make a platform worse.
Architecture should instead answer:
What capability does this system actually require, and what is the simplest reliable way of providing it?
Sometimes the correct answer is Kafka.
Sometimes it is RabbitMQ.
Sometimes it is a Redis-backed queue.
Sometimes it is simply: we do not need asynchronous messaging yet.
The same applies across the diagram.
The modern architect’s job is increasingly one of composition
There was a time when a large part of software architecture meant deciding how application code itself should be structured.
That remains important, but a modern SaaS architect must increasingly reason about a wider system:
- which capabilities belong inside the application;
- which belong at the edge;
- which should be managed cloud services;
- which should be external SaaS providers;
- which should be self-hosted;
- how identity propagates between them;
- how failures propagate between them;
- where data is allowed to travel;
- how the whole system is observed;
- how it is deployed;
- how it is supported;
- where AI can safely participate.
The architecture is no longer merely the codebase.
It is the ecosystem of technologies, services, policies, people and operational processes required to keep that code useful in production.
And that is perhaps the most striking thing about looking at the complete diagram: the little box marked Application Layer is important, but it is surrounded by an enormous amount of machinery whose job is to make that application dependable enough for somebody else to trust.