Cheatsheet: PlantUML
Last updated 2026-07-20
Basics
Every diagram is wrapped in @startuml / @enduml
Add a title and a single-line comment
Sequence diagrams
Messages: -> solid, --> dashed (reply)
Declare participants and aliases
Activation / lifelines with activate & deactivate
Notes (watch multi-line!)
Single-line note: text must stay on the same line after the colon
Multi-line note: use a note ... end note block. A colon note that wraps to a second line is a syntax error.
Note position: left, right, or over one participant
Class diagrams
Classes with fields and methods
Relationships: inheritance, composition, association
Use case diagrams
Actors, use cases, and include
Activity diagrams
Start/stop, actions, and conditionals (new syntax)
Component diagrams
Components, packages, and links
Styling
skinparam tweaks the look; !theme applies a built-in theme
See also: