An architecture diagram is a picture drawn to explain a system to a particular audience. Its only job is to communicate.

Architecture isn’t diagrams: good architecture is working software. But a good picture is still the fastest way to give someone a shared understanding of a system, and a bad one is a fast way to give them a shared misunderstanding.

The diagram is not the architecture. It’s a conversation starter about the architecture.

Start with an architectural overview

For most systems the single most useful picture is an architectural overview: one diagram that shows the overall shape of the system. It should include:

Don’t worry about strict notation. Borrow symbols that people recognise, from UML or a provider’s icon set, use colour deliberately and add a legend. A rich picture that people understand beats a technically correct one that they don’t.

The best way to use an overview is to talk someone through it. If the diagram can’t survive a five-minute walkthrough with a new team member, it isn’t doing its job.

Cloud diagrams flow left to right

Traditional architecture diagrams were often top-down structures: layers, components and class hierarchies. Because cloud structure is dynamic (things scale, appear and disappear), cloud diagrams are usually more useful when they show the flow of data, left to right, from where a request or event enters the system, through the managed services that process it, to where results end up. Draw what happens, not just what exists.

The C4 model

Simon Brown’s C4 model is a simple, widely used way to draw software architecture at four zoom levels:

  1. Context: the system as a box, with its users and the other systems it talks to.
  2. Containers: the deployable or runnable things inside it (applications, functions, databases, queues).
  3. Components: the major building blocks inside one container.
  4. Code: classes and functions. This is rarely worth drawing by hand.
The four zoom levels of the C4 model1. Contextsystem, users,neighbouring systems2. Containersapps, functions,data stores, queues3. Componentsbuilding blocksinside one container4. Codeclasses & functions:rarely worth drawingzoom in →Most teams get most of the value here
C4's four levels of zoom. Draw deeper levels only where there's real complexity to explain.

Most teams get most of the value from the first two levels. Draw deeper only where there’s real complexity to explain, typically where the architectural profile is high.

Diagrams as code

Diagrams drawn in a separate tool and pasted into a wiki go out of date the day they’re published. Text-based tools such as Mermaid, PlantUML, D2 and Structurizr let you keep diagrams in the repository next to the code, review them in pull requests and regenerate them automatically:

flowchart LR
  user([Customer]) --> api[API Gateway]
  api --> fn[Order function]
  fn --> q[(Order queue)]
  q --> worker[Fulfilment service]
  worker --> db[(Orders table)]

Some tools can also generate diagrams from Infrastructure as Code or from live cloud accounts. They’re useful for checking what actually exists, but generated diagrams show everything, so they rarely communicate as well as one drawn with intent.

Keep them honest