# PlantUML

> A free tool that turns lines of text into UML diagrams. You write it, and it draws it.

**Field:** Design  
**Category:** Design Tools  
**Also known as:** Plant UML, PlantUML Diagram, @startuml

## Think of it like

It is like a note to a painter. You write what goes where, and the painter makes the picture.

## Definition

PlantUML is an open-source tool that draws diagrams from plain text. You write lines between @startuml and @enduml, and it draws the picture. It covers the common UML diagrams, such as sequence, class, activity and state. It also draws mind maps, Gantt charts and network maps. It runs on Java, and many wikis and code editors can show its diagrams.

## Example

Lucy keeps a PlantUML sequence diagram of the checkout in her team's wiki. When the payment step changes, she edits one line and the picture redraws.

## Example code

```plantuml
@startuml
Emma -> Shop: Place order
Shop -> Bank: Take payment
Bank --> Shop: Paid
Shop --> Emma: Order confirmed
@enduml
```

Six lines of text. PlantUML draws four messages between Emma, the shop and the bank.

## Why it matters

It draws strict UML from text, so the picture can live in Git and change with the code. Big teams use it to keep design pictures up to date.

## Common mistake

Expecting GitHub to draw it like Mermaid. GitHub does not show PlantUML in Markdown. You need a server, a plugin or a saved image.

## Three principles

- **Text in, picture out.** Write between @startuml and @enduml.
- **UML and more.** Sequence, class, state, Gantt and more.
- **Runs on Java.** Draws on your machine or a server.

## Related terms

- [Diagramming Software](https://learn.benibix.com/term/design/diagramming-software)
- [Mermaid](https://learn.benibix.com/term/design/mermaid)
- [Structurizr](https://learn.benibix.com/term/design/structurizr)
- [Unified Modeling Language (UML)](https://learn.benibix.com/term/development/uml)
- [Sequence Diagram](https://learn.benibix.com/term/development/sequence-diagram)

## Told apart from

- [PlantUML vs Mermaid](https://learn.benibix.com/compare/plantuml-vs-mermaid): People think PlantUML and Mermaid are the same tool with two names, and they are not. Both turn text into diagrams. Mermaid runs in the browser, and GitHub draws it right inside Markdown. PlantUML runs on Java and covers more of UML, but GitHub will not draw it for you. Pick Mermaid for a README, and PlantUML for strict UML.

## Taught in

- [Diagramming Software](https://learn.benibix.com/learn/design-design-tools/diagramming-software): Design Tools, 12/12

![Three panels, each making the same two boxes, Shop above Pay, joined by an arrow. Sketch by hand, like Excalidraw: wobbly hand-drawn boxes and a curved arrow, marked rough on purpose. Drag shapes, like draw.io: a strip of shapes on the left and two neat boxes joined by a straight line, marked move a box and the line follows. Write text, like Mermaid: two lines of code, flowchart TB and A Shop arrow B Pay, with an arrow down to the two boxes it draws.](https://learn.benibix.com/diagrams/des-diagram-tools.svg)

---

Source: https://learn.benibix.com/term/design/plantuml
Author: Behnia Zarei (a developer in Vienna, Austria, who builds and teaches data, AI and business intelligence at BENIBIX)
Publisher: BENIBIX Learn (https://learn.benibix.com/)
Last updated: 2026-11-19
Licence: CC BY 4.0 (https://creativecommons.org/licenses/by/4.0/). Quote freely with attribution.
