Three-tier web application architecture diagram
Browser, load-balanced web servers, an application API, a cache and a replicated database.
About this template
The three-tier layout is still the starting point for most web products: a presentation tier that serves pages, an application tier that holds business logic, and a data tier that stores state. This template draws that shape with the pieces teams usually add first, a CDN, a load balancer, a cache and a read replica.
Use it as the first diagram in a design doc. It is detailed enough to discuss where requests go and where state lives, and small enough that people read it.
What is in the diagram
- CDN
- Serves static assets from the edge so the web servers only handle dynamic requests.
- Load balancer
- Spreads HTTPS traffic across the web servers and removes unhealthy ones.
- Application API
- Stateless business logic. Because it holds no session state it can scale horizontally.
- Cache
- Read-through cache in front of the database for hot keys such as sessions and product pages.
- Primary database and read replica
- Writes go to the primary; the replica takes reporting and read-heavy queries.
More software architecture templates
Microservices
Clients, an API gateway, four services with their own data, and an event bus between them.
Event-driven architecture
Producers, a broker topic, independent consumers and a dead-letter queue.
RAG pipeline
Retrieval-augmented generation: ingestion on one path, question answering on the other.