Built for AI-first workflows

Diagram editor that works
with your AI agent

Mermaid Code is a local-first desktop app. Diagrams live as plain .mmd files — AI agents can read, write, and update them directly. No copy-pasting. No browser automation.

Download View on GitHub
Mermaid Code screenshot

AI Workflow

Let your agent write the diagrams

Because diagrams are plain files on your filesystem, any AI coding agent can generate or update them as part of its normal workflow.

1
Ask your agent "Generate an architecture diagram for this module and save it to docs/architecture.mmd"
2
Agent writes the file No API calls to a web editor, no clipboard tricks — just a regular file write.
3
Preview updates instantly The built-in file watcher detects the change and refreshes the diagram automatically.
# Claude Code example
$ claude "Generate a sequence diagram for the
  auth flow and save it to docs/auth.mmd"
AI workflow diagram

Features

Everything you need,
nothing you don't

Built on Mermaid Live Editor, enhanced with desktop-native capabilities via Tauri.

📁

File Manager Sidebar

Open any folder. Browse files in a tree or thumbnail grid. Drag and drop .mmd files directly onto the window.

🗂

Multi-tab Editing

Open multiple diagrams simultaneously. Tabs and active files are restored per folder on next launch.

💾

Auto-save

Changes are saved automatically with a 2-second debounce. Toggle it off when you need manual control.

⌨️

Vim Mode

Full Vim keybindings in the Monaco editor, including yank-to-clipboard and custom :w / :q commands.

Keyword Autocomplete

Diagram-type-aware suggestions in the editor. Start typing and get context-sensitive completions.

🎨

Visual Config

Set theme, layout direction, and font family using a visual form — no JSON editing required.

🔒

Fully Local

Architecture diagrams, database schemas, and business flows never leave your machine. No telemetry, no cloud sync.

🖥

macOS & Windows

Native app on both platforms. "Open with" support — double-click any .mmd file to open it directly.


Experimental

Built-in MCP Server

Mermaid Code includes a built-in Model Context Protocol server. AI agents can interact with the running app directly — no filesystem access required.

Available tools

list_diagrams

Get the opened folder, list of .mmd files, and the active tab.

preview_diagram

Preview Mermaid code in the Draft tab without saving to disk.

Configure Claude Code

$ claude mcp add --transport http \
  mermaid-code-mcp \
  http://localhost:37079/mcp

Enable the server: open Mermaid Code → menu icon → toggle MCP Server on.


Install

Get started in seconds

Download the latest release for macOS or Windows, or install via Homebrew.

$ brew tap m8524769/tap
$ brew install --cask mermaid-code
Download the latest installer from the GitHub Releases page.
Available for macOS (Apple Silicon & Intel) and Windows.
macOS note: The app is not signed with an Apple Developer certificate. On first launch, go to System Settings → Privacy & Security and click Open Anyway. If blocked, run:
xattr -dr com.apple.quarantine "/Applications/Mermaid Code.app"