Start with one question
These choices are not an exhaustive catalog of C4 views. Use the smallest set that explains your decision. A container-level drawing with servers added to it does not automatically become a clear deployment view: the reader must be able to distinguish the logical application, its instances, and the infrastructure hosting them.
Example 1: two logical containers
The fictional Report system has a Go application that builds reports and a PostgreSQL data store that keeps the results. A C4 container is an application or data store; the term does not mean a Docker container.Report API remains useful even if staging and production deploy it differently.
Example 2: instances on two staging hosts
Now ask a different question: where do the same logical elements run? This example places one application instance on an App host VM and one data-store instance on a Data host VM. The environment is explicitly illustrative staging, not an observation of a real deployment.
These are separate authored files. The mapping above is maintained by the author; the renderer does not infer or synchronize it. For facts shared across many views, see the shared-inventory example. For an observed baseline versus an unimplemented proposal, keep current and target states separate as well.
A request scenario needs more than a dependency arrow
The application-to-store arrow above says the dependency exists. It does not specify when a transaction starts, which result is returned, or what happens on failure. For the fictional “build one report” scenario, first write the ordered steps: a caller submits a request; the API computes a report; the API stores the result; the store acknowledges the write; the API returns a report identifier. This scenario makes assumptions that must be checked against your implementation. An asynchronous implementation would need a different interaction contract. If ordering and replies are the point, a Mermaid sequence diagram is an option to evaluate. A C4 dynamic view can also represent an individual scenario with ordered interactions. Merely rotating a static diagram into top-down projection does not add ordering or timing information.Reproduce the two sketches
Use the installation guide, or build from this repository with Git and Go 1.25 or later:topology.svg and an HTML preview. Record the source revision; on Windows use isotopo.exe. Copy a YAML file before adapting it, then run isotopo serve your-copy.yaml to edit that copy in local Studio. Studio saves accepted source changes to the served file.
Try moving the data-store instance into the App host boundary. That changes the deployment sketch; it need not change the logical container view. Then try splitting report generation into a separate worker application. That changes the logical view and requires revisiting the deployment mapping and request scenario. The two edits are different architecture decisions even if both involve moving boxes on a canvas.
Review meaning before appearance
C4’s notation guidance allows different visual styles while emphasizing understandable titles, element types, responsibilities, technologies and relationships. Our two drawings are original teaching sketches, not an assertion of complete C4 conformance. Before publishing your version, check:- Does the image identify its scope and, for a deployment view, its environment and evidence status?
- Can a reader distinguish an application from one instance and from its host?
- Does each arrow have one clear meaning? Is that meaning consistent with its direction?
- Do labels and the caption explain the view without relying on color alone?
- Which code, configuration or observation supports each statement? Which parts remain assumptions?
validate command checks the diagram document; it cannot establish these system facts. An agent should preserve the selected view, cite the evidence it used, and leave unknown relationships unresolved rather than filling them with plausible-looking connections.
Compare open-source tools · Choose an input format · Draw from code evidence