Draw.io
Enables AI agents to programmatically create, modify, and analyze Draw.io diagrams through the Model Context Protocol. Supports generating architectural diagrams, flowcharts, and visualizations with bidirectional communication between AI systems and
What is Draw.io?
Draw.io is a Model Context Protocol (MCP) server that allows AI assistants like Claude, Cursor, and VS Code to enables ai agents to programmatically create, modify, and analyze draw.io diagrams through the model context protocol. supports generating architectural diagrams, flowcharts, and visualizations with b...
Enables AI agents to programmatically create, modify, and analyze Draw.io diagrams through the Model Context Protocol. Supports generating architectural diagrams, flowcharts, and visualizations with bidirectional communication between AI systems and
This server falls under the Developer Tools category on MCPgee, the world's largest MCP server directory with 33,000+ servers.
Features
- Enables AI agents to programmatically create, modify, and an
Use Cases
Maintainer
Works with
Installation
Manual Installation
npx draw-io-mcp-serverConfiguration
Configuration Details
claude_desktop_config.json
Performance
Response Metrics
Resource Usage
How to Set Up and Use Draw.io
The Draw.io MCP Server (drawio-mcp-server) enables AI agents to programmatically create, inspect, and modify Draw.io diagrams through the Model Context Protocol, establishing a bidirectional communication channel between AI systems and the Draw.io desktop application or VS Code extension. It supports generating architectural diagrams, flowcharts, sequence diagrams, and cloud infrastructure visualisations using built-in AWS, GCP, Azure, and Cisco stencil libraries that are auto-discovered at runtime. Multiple AI agents can safely operate on the same diagram concurrently thanks to FIFO serialisation, and diagrams can be imported and exported in XML, SVG, PNG, and Mermaid formats.
Prerequisites
- Node.js 18 or later (for npx)
- Draw.io desktop application installed, OR the Draw.io VS Code extension
- The Draw.io app or VS Code extension must be open with a file for the MCP server to connect to
- An MCP-compatible client such as Claude Desktop, Claude Code, or Cursor
Install Draw.io desktop or VS Code extension
The MCP server connects to a running Draw.io instance. Install the desktop app from diagrams.net or the Draw.io Integration extension in VS Code, then open a .drawio or .xml diagram file.
Test the server via npx
Run the server once from the terminal to confirm it starts and can connect to Draw.io. The --editor flag is required to enable the bidirectional editing protocol.
npx -y drawio-mcp-server --editorAdd the server to your MCP client config
Add the following block to your claude_desktop_config.json or equivalent MCP host configuration file.
{
"mcpServers": {
"drawio": {
"command": "npx",
"args": ["-y", "drawio-mcp-server", "--editor"]
}
}
}For Claude Code, use the mcp add-json command
Claude Code users can register the server with a single CLI command.
claude mcp add-json drawio '{"type":"stdio","command":"npx","args":["-y","drawio-mcp-server","--editor"]}'Restart your MCP client and open a diagram
Restart the MCP client. Ensure a Draw.io file is open in the desktop app or VS Code. The server's tools will be ready: document discovery, shape inspection, shape/edge editing, page and layer management, and import/export.
Draw.io Examples
Client configuration
claude_desktop_config.json entry for the Draw.io MCP server.
{
"mcpServers": {
"drawio": {
"command": "npx",
"args": ["-y", "drawio-mcp-server", "--editor"]
}
}
}Prompts to try
These prompts generate, modify, and inspect Draw.io diagrams through the MCP tools.
- "Create an AWS architecture diagram showing an ALB, two EC2 instances, an RDS database, and an S3 bucket"
- "Add a new page called 'Data Flow' to the open diagram and draw a sequence diagram of the login process"
- "Create a three-tier web application diagram with presentation, logic, and data layers on separate layers"
- "Import this Mermaid flowchart into the current diagram: graph TD; A-->B; B-->C"
- "List all pages in the open diagram and describe the shapes on each page"
- "Export the current diagram page as SVG"Troubleshooting Draw.io
Server starts but cannot find an open Draw.io document
Ensure the Draw.io desktop app or VS Code extension is open and has a diagram file loaded. The MCP server connects to a running Draw.io instance — it cannot create diagrams without an open host application.
npx drawio-mcp-server fails with a package not found error
Run `npm install -g drawio-mcp-server` to install the package globally, then restart and try the npx command again. Alternatively, pin the version: `npx -y drawio-mcp-server@latest --editor`.
Concurrent agent edits corrupt the diagram
The server uses FIFO serialisation for safe concurrent access, but ensure all agents are using the same server instance (not separate server processes). If running multiple AI agents, route all their diagram calls through the same MCP server process.
Frequently Asked Questions about Draw.io
What is Draw.io?
Draw.io is a Model Context Protocol (MCP) server that enables ai agents to programmatically create, modify, and analyze draw.io diagrams through the model context protocol. supports generating architectural diagrams, flowcharts, and visualizations with bidirectional communication between ai systems and It connects AI assistants to external tools and data sources through a standardized interface.
How do I install Draw.io?
Follow the installation instructions on the Draw.io GitHub repository. Clone the repo, install dependencies, and add the server config to your AI client.
Which AI clients work with Draw.io?
Draw.io works with all major MCP-compatible AI clients including Claude Desktop, Claude Code, Cursor, VS Code (GitHub Copilot), Windsurf, and Cline.
Is Draw.io free to use?
Yes, Draw.io is open source and available under the MIT License license. You can use it freely in both personal and commercial projects.
Draw.io Alternatives — Similar Developer Tools Servers
Looking for alternatives to Draw.io? Here are other popular developer tools servers you can use with Claude, Cursor, and VS Code.
Ecc
★ 188.2kThe agent harness performance optimization system. Skills, instincts, memory, security, and research-first development for Claude Code, Codex, Opencode, Cursor and beyond.
Javaguide
★ 155.8kJava 面试 & 后端通用面试指南,覆盖计算机基础、数据库、分布式、高并发、系统设计与 AI 应用开发
Gemini CLI
★ 104.5kA secure MCP server that wraps the Google Gemini CLI, allowing clients to query Gemini models using local OAuth sessions without requiring an API key. It provides tools for model interaction and diagnostics with built-in protection against command in
Awesome MCP Servers
★ 87.3k⭐ Curated list of Model Context Protocol (MCP) servers - tools that extend Claude Desktop, Cursor, Windsurf, and other MCP clients with custom capabilities.
MCP Servers
★ 86.0kModel Context Protocol Servers
CC Switch
★ 77.5kA cross-platform desktop All-in-One assistant for Claude Code, Codex, OpenCode, OpenClaw, Gemini CLI & Hermes Agent. Only official website: ccswitch.io
Browse More Developer Tools MCP Servers
Explore all developer tools servers available in the MCPgee directory. Each server includes setup guides for Claude, Cursor, and VS Code.
Set Up Draw.io in Your Editor
Choose your AI client for step-by-step setup instructions.
Quick Config Preview
Add this to your claude_desktop_config.json or .cursor/mcp.json
Ready to use Draw.io?
Browse our complete directory of 33,000+ MCP servers, read setup guides for your editor, and start building with the Model Context Protocol.