Find your next open-source project

Search by name, purpose, or keyword — or paste a GitHub repository URL

jgraph/drawio-mcp

AI Engineering

MCP server lets AI assistants generate and open editable draw.io diagrams.

5,852
360
JavaScript
Apache-2.0
9 months old

What it does

drawio-mcp is the official MCP integration for draw.io. It gives AI assistants tools to turn prompts into draw.io XML or Mermaid diagrams and lets users open, copy, or download them as editable files. It targets people who want diagrams produced inside chat or coding assistants rather than drawn by hand.

The repository bundles four delivery paths: a hosted MCP App Server that renders diagrams inline in compatible chat hosts, an npm-published MCP Tool Server that opens diagrams in the draw.io editor, assistant plugins for coding CLIs, and paste-only project instructions that need no MCP server. A shared XML reference and a shape search index are reused across them.

Quick start

The fastest path uses the hosted MCP endpoint. Add https://mcp.draw.io/mcp as a remote MCP server in a compatible host such as Claude.ai, ChatGPT, VS Code with GitHub Copilot, Cursor, or GitHub Copilot CLI (source:18). In Claude.ai it can also be added from the connector directory in one click (source:19). No installation is required.

For a local stdio setup, run the npm package:

npx @drawio/mcp

Then register it as an MCP server in your client; per-client setup instructions are in the tool server documentation. For Claude Code, install the plugin from the repository marketplace:

/plugin marketplace add jgraph/drawio-mcp
/plugin install drawio@drawio

After setup, ask the assistant for a diagram. The App Server draws it inline, while the tool server opens it in the draw.io editor.

The tools

The App Server exposes create_diagram for draw.io XML and Mermaid, search_shapes for finding exact shape styles among 10,000+ library shapes, get_drawio_reference for generation guidance, and an optional create_semantic_diagram fast mode. Fast mode lays out flowcharts and swimlanes from a literal description and is only selected when the prompt asks for speed, low effort, or low token cost (source:24). It is limited to flowcharts and swimlanes in the default theme, and should not be combined with manual layout passes.

Constraints

Data residency depends on the chosen path. The hosted App Server sends diagram requests to draw.io, while the self-hosted App Server, tool server, and assistant plugins keep diagram content local; plugin exports require a local draw.io Desktop CLI (source:2). Rendering still loads viewer code from diagrams.net unless self-hosting build options or DRAWIO_BASE_URL are set. The assistant plugins that bundle the hosted App Server also send diagrams to mcp.draw.io. End-to-end isolation additionally requires a locally hosted LLM.

Plugin export to PNG, SVG, or PDF uses draw.io Desktop, and the url output mode opens diagrams at app.diagrams.net. Mermaid diagrams cannot use the optional ELK or libavoid layout passes. The project is Apache-2.0 licensed.

HotRepo's take

The repository entered the JavaScript daily list on 2026-11-18 at position 7 with 5,852 stars and 9 stars gained that day. The single snapshot only establishes that placement; it does not support a growth trend. What stands out technically is the range of entry points: one hosted endpoint, an npm server, coding-assistant plugins, and instructions that need no install. That lowers the barrier for trying draw.io diagrams inside an existing assistant, while the README's data-residency table gives deployment teams something concrete to evaluate before choosing the hosted path.

Written by AI from the project's README, updated . The project's own docs are the source of truth.

Hacker News

The official draw.io MCP Server
▲ 3 · 0 comments · August 5, 2026

You might also like

  1. jgraph/drawio-desktopA desktop wrapper of the draw.io diagram editor for Windows, macOS and Linux that works offline.JavaScript63,817
  2. grafana/mcp-grafanaAn MCP server that lets AI assistants read and operate a Grafana instance for observability work.Go3,611
  3. figma/mcp-server-guideConnect AI coding agents to Figma files so they can generate code from designs and write back to the canvas.Python2,169
  4. phone-harness/mcpA hosted MCP server that lets AI agents control real iPhones and Android emulators in the cloud.Python812
  5. ysunyang4/NexusA local MCP control plane that lets web-based AI assistants inspect, edit, build and run code on a developer's machine within sandboxed project boundaries.TypeScript119