- 8 minutes to read

Building a Diagram

The Toolbox is the heart of the C4 Designer. It gives you everything you need to populate a diagram: element shapes, boundary containers, and connector types. You drag from the Toolbox and drop onto the canvas, bind the shape to a Repository entity, and the Designer saves each step at once.

Build a C4 diagram in the Designer: filter the Toolbox, drag a Container onto the canvas and bind it to a Service, animated walkthrough (7.12)
Animated walkthrough: Steps 1 to 3 on an empty Draft L2 Container diagram over the Order-to-Cash demo, from the Service filter chip to a Container bound to an Order-to-Cash Service.

The Toolbox is only visible when the diagram is in Draft state. An Active diagram opens read-only, without the Toolbox. Click Clone as Draft in the toolbar to get a Draft you can edit (see Diagram Lifecycle).

View, Edit, and Render Options

When you are working with a C4 diagram, these pages cover the main read-only and editing paths:

Action Page
View Mermaid View
Edit C4 Designer
Edit Properties Diagram Lifecycle
Show in Mapify Mapify Rendering
Show in Mermaid Mermaid Rendering

For C4-specific read-only rendering, Mermaid View is the dedicated page. For interactive relationship exploration, use Mapify Rendering. For static relationship exploration, use Mermaid Rendering.

Understanding the Toolbox

The Toolbox panel sits on the left side of the Designer. Its collapsible sections depend on the diagram type (L1 Context, L2 Container, L3 Component, and so on): only shapes that make sense for the current level are shown. On an L2 Container diagram, for example, the sections are:

Section Contents
Persons Human actors, internal and external
Containers Runtime deployable units: Container (a Container Instance belongs on a Deployment diagram)
Databases Container DB and Cache / Key-Value
Queues & Streams Container Queue
External Systems The System shapes, internal and external, for the Systems around the one the diagram zooms into
External Containers The external variants of the Container shapes
Boundaries Boundary and System Boundary
Connectors Synchronous, Asynchronous, and Bidirectional connection types

Above the sections, the filter chips All, System (Systems), Service, and Contract (Contracts) narrow the Toolbox to the shapes that bind to that kind of Repository entity. There is no search box: the filter chips are how you narrow the shapes. Each tile shows the shape's icon and name. See Shapes and Toolbox Reference for the full availability matrix.

Collapsing the Toolbox

The Toolbox header has a pin button and a close button. Close the Toolbox to give the canvas more space; a closed Toolbox comes back through its tab on the left side of the canvas.

Adding Elements to the Canvas

Step 1 — Find the right shape

Click a filter chip, for example Service, or open the section that holds the shape. The shape names match the C4 tier and the diagram type, for example Container, Container DB, and Cache / Key-Value on an L2 Container diagram.

Shapes come in an internal and an external variant. External variants are named (External) or (Ext), such as Container (External) or System DB (Ext), and show a overlay icon. See Shapes and Toolbox Reference for the full convention.

Step 2 — Drag onto the canvas

Click and hold a Toolbox tile, then drag it onto the canvas. Release the mouse button to drop the shape at that position.

The shape is created at the drop coordinates and saved at once.

Step 3 — Bind to a Repository entity

A newly dropped shape is an unbound placeholder. To connect it to a real entity in your Repository:

  1. Click the shape's header: Node Properties opens (see Editing Elements).
  2. Under Binding, click Resolve….
  3. Pick the tab and type to filter the Repository entities. New 7.12 The tabs follow the shape: a Container binds a Service or a Contract (Use existing Service, Use existing Contract), never a System; a System or Person binds a System (Use existing System); a Component on a Component diagram binds an Endpoint (Use existing Endpoint); an Infrastructure Node binds nothing.
  4. Click Confirm.

The panel then shows the entity's name, description, and operational status, and the shape on the canvas carries the entity's name. The binding is saved at once. When UseContracts is enabled, the same resolver also supports direct Contract binding. See Repository Bindings for the full workflow.

Adding a shape from the right-click menu

Right-click an empty part of the canvas to open its menu. It offers Add with the shapes of the current diagram type, and Assistance, the Diagram Assistance for the diagram.

Adding Boundaries

Boundaries group related elements inside a named container, representing a System, a Service, or a Domain in your architecture, or just a grouping.

  1. Open the Boundaries section in the Toolbox.
  2. Choose a boundary type. The tiles depend on the diagram type:
    • L0 System Landscape and L1 Context: Boundary and Enterprise Boundary (a top-level organisational grouping)
    • L2 Container: Boundary and System Boundary (wraps a System's containers)
    • L3 Component: Boundary and Container Boundary (wraps the components of a Service or Contract)
    • Dynamic: Boundary, System Boundary, and Enterprise Boundary
    • Deployment: Deployment Node
  3. Drag the boundary onto the canvas.
  4. Drop elements inside the boundary, or drag existing elements into it.

Add a System Boundary from the Toolbox, drop a Container into it and bind it to a Service, then drag a second bound Container into the boundary, animated walkthrough (7.12)
Animated walkthrough: on a Draft L2 Container diagram, a System Boundary from the Toolbox, a Container dropped into it and bound to an Order-to-Cash Service with Resolve…, then the first Container dragged in. Both stay inside the boundary, and bound, after a reload.

The boundary under the pointer lights up as the drop target. A shape you drop from the Toolbox, or add with the right-click Add menu, inside a boundary belongs to that boundary, also when the boundary is new and empty. A shape you drag into a boundary belongs to it as soon as you drop it.

Boundaries auto-expand as you add more elements. You can also resize a boundary manually by dragging its bottom-right corner handle. Adding, moving, resizing, or binding a boundary never changes the Repository Bindings of the shapes inside it.

Info

Click the boundary header to open Boundary Properties, and bind the boundary with Shape Binding > Resolve…. What it binds follows the kind: an Enterprise Boundary or a Boundary binds a Domain (tab Use existing), a System Boundary a System, a Container Boundary a Service or Contract, and a Deployment Node nothing. New 7.12 The subject boundary of a Container or Component diagram, made by Next layer, the import, or a generator, follows the scope (Container) or the subject (Component) and is locked. See Organising with Boundaries for details.

Moving Elements

Moving a node

Click and drag any element on the canvas to reposition it. Connectors update in real-time as you drag. When you release the mouse button, the position is saved automatically.

If you drag a node over a boundary, it adopts that boundary as its parent (reparenting). The boundary that most tightly contains the node's centre is the one chosen. See Organising with Boundaries.

Moving a boundary

Click and drag the boundary header to move the entire boundary and all of its contained elements together. The relative positions of elements inside the boundary are preserved.

Keyboard movement

Select a node or boundary and use the Arrow keys to nudge it by 1 pixel, or Shift + Arrow for 10-pixel steps. See Keyboard Shortcuts.

Auto-Arrange

The Auto-arrange button in the canvas toolbar, at the top left of the canvas (see Navigating the Canvas), runs a server-side layout algorithm that automatically positions all elements in a tidy grid. It is useful when:

  • You have just imported a diagram and the layout is cluttered
  • You want a clean starting point before manual refinement

When you click Auto-arrange, the dialog Confirm intent to Auto-arrange asks:

Tip

  • "This will permanently re-position all shapes. Consider creating a copy before auto-arranging. This is a one-way operation and cannot be undone."

Click Yes to proceed, or No to keep your current layout. Auto-arranging overwrites all manual positions, so clone the diagram first (Diagram Lifecycle) when the layout matters.

Auto-arrange moves every shape and boundary of the diagram and saves the new positions. If it fails, the dialog shows the message in a red banner.

Info

C4 diagrams, including Auto-arrange, need a Mapify license; see License Options and Feature Matrix. Without it, every C4 page shows Upgrade Required. Running Auto-arrange also needs Modify in the Permission Set for C4 Diagram Sets, or the Administrator role. New 7.12 Like every Designer save, it also needs Create and Modify on Systems, Services, Integrations, and Domains (plus Contracts when Contracts are on), and Access on every Repository part C4 shows; otherwise the Designer answers with an error that lists the missing rights.

Frequently Asked Questions

The Toolbox is not visible

The Toolbox is hidden when the diagram is Active (read-only), or when you closed it. On an Active diagram, click Clone as Draft in the toolbar and edit the Draft. A closed Toolbox comes back through its tab on the left of the canvas.

I dropped an element in the wrong place

Simply drag it to the correct position. The new position saves automatically on release.

Can I add the same shape multiple times?

Yes. Drag the same Toolbox tile multiple times to create multiple instances of a shape. Each instance becomes a separate node that can be independently bound and positioned.

Should I bind nodes immediately or finish layout first?

Either approach works. Many users prefer to sketch the full layout first (adding and positioning all unbound shapes), then bind each shape to a Repository entity in a second pass. If your environment uses UseContracts, you can bind contract-first directly instead of binding to a service first. See Repository Bindings.

Next Steps