Layered architecture
Layered architecture organises an application into horizontal layers — typically presentation, business logic, data access — with each layer depending only on the layer below. The pattern is the most traditional enterprise architecture and remains the default for many CRUD applications, though more flexible patterns (hexagonal, clean) have largely displaced it for complex domains.
Strict layering (each layer talks only to the one immediately below) is rigid; relaxed layering (a layer can skip down through layers it doesn't depend on logically) is common but blurs the boundaries. The pattern's strength is familiarity — every developer has built a layered app — and its weakness is that the layers often don't map to real architectural boundaries (the business logic layer becomes a grab-bag, the data layer becomes anaemic). Layered architecture remains the right starting point for simple CRUD; for anything with complex domain logic, hexagonal or clean architecture provides better isolation of the parts that change most.
Related terms
- N-tier architecture
N-tier architecture distributes an application across N physical tiers — typically presentation (browser or client), application server (business logic), and database.
- Clean architecture
Clean architecture, presented by Robert C.
- Hexagonal architecture
Hexagonal architecture (also called ports and adapters), introduced by Alistair Cockburn in 2005, structures an application so the core domain logic depends only on abstract 'ports' — and concrete adapters (web framework, database, message bus) plug into those ports from outside.