Styling and appearance

By default, each C4 element type (Person, External System, Software System, Container, Component) has a fixed colour and icon. You can override these on a per-element basis or create custom display types to apply a consistent style to a group of elements without changing their type.

Recolouring the fixed element types

To adjust the colour of a C4 element type (e.g. make all Containers a different shade), open the Type & style settings dialog from the Settings (palette) button in the editor toolbar.

The dialog shows two sections:

Element types (locked) — the five fixed C4 types. You can customize their border, background, and font colour for this project, or add a dashed border and a default icon. Changes to a type apply everywhere it's used.

Display types (user-defined) — custom styles you create to override a type's appearance on specific elements.

Pick the colour fields to change them, or click the Dash checkbox to toggle a dashed border. Every change applies immediately.

Creating and managing display types

A display type is a custom style you name and define once, then apply to any elements you want. Use them to visually distinguish:

  • Roles or teams ("API Team", "Data Team") — each with their own colour.
  • Deployment zones ("Internal", "Public-facing") — visual separation without adding elements.
  • Technology clusters ("Legacy", "Modern") — quick visual scan of what's what.
  • External partners — a distinct look for third-party systems.

Add a display type: in the Type & style settings dialog, type a name in the "New display type name" field at the bottom and press Enter (or click Add). The new type appears in the Display types section with default colours.

Customize its style: click the colour fields to set border, background, font, and selection colours. Check Dash for a dashed border, and pick a default icon (the icon automatically appears on any element using this type).

Apply to an element: in the element's form, use the Display type dropdown to assign the custom style. The element now renders with those colours instead of its element type's.

Rename a display type: click the type's name in the dialog to edit it inline. Renaming updates all elements using it.

Delete a display type: click the × button beside the type. Elements using it revert to their element type's style. The delete is immediate — you can undo it with your browser's undo if you act quickly.

Connection line styles

Elements aren't the only thing you can give a look to. The style dialog's Connection line styles section lets you define named kinds of line — Async, Secure, Legacy — each with a colour, a width, and solid, dashed, or dotted strokes. Every connection can then name one.

Define a style: in the Type & style settings dialog, find Connection line styles, type a name, and add it. Set its colour, width, and dash; a preview draws the actual stroke beside it.

Apply it: select a connection and pick the style in the Line style field of its details pane. Leave it on Default line and nothing changes.

One set, all three diagram types. A style defined here is the same style the deployment and F4 connection forms offer — a kind of line reads the same wherever it is drawn. Rename or delete one and every connection using it, in every model, keeps up; a connection naming a style the project no longer has simply draws as a normal line.

Selection still reads clearly. Because you can define a style that looks exactly like the selection highlight, a selected line no longer relies on colour and thickness alone — it keeps its own style and gains a glow, so you can always tell which line you have hold of.

Line styles travel with Copy / Paste styles between projects, and a copied diagram brings its connections' styles with it.

Boundary group descriptions

A group can carry a description of its own, the same markdown field an element or a diagram has. Select the group and fill in Description in its details pane. It shows in the viewer's side panel, and it travels into the exported document under a Boundaries listing alongside the group's members — so a boundary that means something ("everything owned by the payments team") explains itself to a reader who wasn't in the room.

Groups are covered in full under Containers & drill-down.

Icon picker

Every element has an optional Material Symbols icon (shown in the top-right corner of the card). You can set it in the element's form under Icon, or as a default for a display type under Type & style settings.

Click the icon button to open the picker, search for a symbol by name (e.g. "database", "cloud", "person"), and select one. The picker searches the full Material Symbols Outlined library. Leave it empty to use the default icon for the element type.

Group fill opacity

When you have multiple overlapping groups on a diagram, their fills can become visually dense. Use the Group fill opacity slider at the top of the Type & style settings dialog to adjust the transparency of all group boundaries at once.

Slide it lower for a more transparent feel (easier to see elements inside), or higher for a more opaque, distinct boundary. The setting is global — it affects every group on every diagram in the project.

Where next