UML diagram

Updated

A UML diagram is a diagram drawn in the Unified Modeling Language, a standard visual notation for describing the structure and behavior of software systems. UML was adopted as a standard by the Object Management Group in 1997. Because the notation is shared, a developer, an analyst and an architect can read the same diagram in the same way.

Types of UML diagrams

UML diagrams fall into two groups.

Structure diagrams show what a system is made of:

  • Class diagram: classes, their attributes and methods, and the relationships between them.

  • Component diagram: the larger parts of a system and their interfaces.

  • Deployment diagram: the servers and devices that software runs on.

  • Object and package diagrams: instances at a moment in time, and how code is grouped.

Behavior diagrams show what a system does:

  • Use case diagram: the goals users can reach with the system.

  • Activity diagram: a workflow of steps and decisions, similar to a flowchart.

  • Sequence diagram: messages between participants in time order.

  • State machine diagram: the states of an object and what moves it from one to another.

When to use a UML diagram

  • Before building: to agree on a design and find problems while they are cheap to fix.

  • While building: to explain one part of the system to a teammate.

  • After building: to document how the system works for new team members.

Most teams use a few diagram types, usually class, sequence, activity and use case, and draw them only where a picture is clearer than text.

How to create a UML diagram

  1. Decide the question. "How do these services talk?" suggests a sequence diagram. "What data does an order hold?" suggests a class diagram.

  2. Set the level of detail. A sketch for a discussion needs less than a specification.

  3. Draw the main elements first, then add relationships, labels and multiplicities.

  4. Review it with the people who will build from it, and update it when the design changes.

Example

Lucas designs a booking system for a dental practice. A use case diagram lists what patients and receptionists can do. A class diagram defines Patient, Appointment and Dentist. A sequence diagram shows how an online booking checks availability and sends a confirmation.

UML diagram vs other diagrams

UML is general purpose. An ER diagram is specific to database design, and the C4 model is a simpler set of architecture diagrams for explaining a system at several levels of zoom.

UML diagrams in MockFlow

Describe what you need and UML diagram with AI drafts it on a MockFlow board, ready to edit with your team. The UML diagram tool page shows the shapes available, and templates such as the UML sequence diagram and UML deployment diagram give a starting point. See also the whiteboard for developers.

MockFlow

Turn ideas into plans on one board.

No account needed
mockflow.com/new

Open a blank board in one click. Boards last 24 hours, so sign up to keep one.

MCPBrainstorm with MockFlow MCP

Add MockFlow as an MCP connector in Claude, Cursor, or any MCP-compatible AI assistant to generate flowcharts, mindmaps, architecture diagrams, and 16 types of visualizations.

Desktop App MCP Powerful
CLI Web MCP Developer
Web MCP Easiest

Built into the MockFlow Desktop App. AI creates visuals directly on your open canvas — no URLs, no waiting.

1
Open Desktop App → open a MockFlow project
2
In Claude Code / Cursor, run:
claude mcp add --transport http -s user mockflow-ideaboard http://localhost:21193/mcp
3
Ask: "Create a flowchart for..."

Best for: Designers, product teams, daily MockFlow users.

Download Desktop App →

Install from npm, log in via browser (OAuth), and boards are saved to your MockFlow account.

1
npm install -g @mockflow/ideaboard-mcp
2
mockflow-ideaboard-mcp login
3
mockflow-ideaboard-mcp

Best for: Developers using Claude Code, Cursor, or VS Code Copilot.

npm Package →

Add MockFlow as a connector in Claude.ai or ChatGPT. No installation. A new board is created and you get a shareable URL.

1
Open Claude.ai → Settings → Connectors
2
Paste this URL, then click Connect and sign in to MockFlow: https://app.mockflow.com/ideaboard/connector/mcp
3
Ask Claude to create a flowchart — done!

ChatGPT: use https://app.mockflow.com/ideaboard/mcp and save its boards to your account to keep them

Best for: Managers, marketers, anyone using Claude.ai or ChatGPT in the browser.

Welcome back
Don't have an account? Sign up

Faster ways in

Sign in with an account you already use.