Server facts
mcp_excalidraw MCP Server
GitHub stars
2,687
Last commit
Nov 10, 2026
Runtime
node
License
MIT
Project
- Author
- yctimlin
- Repository
- github.com/yctimlin/mcp_excalidraw
- License
- MIT
- Category
- Design & Creative
Tech
- Runtime
- node
- Transports
- stdio
- Remote access
- No
- Authentication
- None
Activity
- GitHub stars
- 2,687
- Last commit
- Data as of
Tags
- drawing api
- excalidraw
- mcp excalidraw
Overview
Unlike Excalidraw's official chat-widget MCP that streams single-prompt visuals into a conversation, `mcp-excalidraw-server` gives coding agents a persistent local diagramming workbench. Under the hood, an auto-started canvas server (`http://127.0.0.1:3000`) pairs an Excalidraw web UI, REST API, and WebSocket sync with your choice of CLI (`npx -y mcp-excalidraw-server`), agent skill, or a 27-tool stdio MCP server speaking both MCP `2026-07-28` and legacy `initialize`. Agents create and patch individual elements, check layouts via `describe_scene` and deterministic headless PNG screenshots rendered in Node without a browser tab, and export byte-stable `.excalidraw`, Obsidian `.excalidraw.md`, or editable `.excalidraw.png` files straight into your repository.
Setup needs only Node.js 20 or higher and zero API keys under the MIT license: register `npx -y mcp-excalidraw-server` in Claude Desktop, Cursor, Claude Code (`claude mcp add`), Codex CLI, OpenCode, or Antigravity—or install the portable CLI skill via `install-skill` for coding agents. By default scenes stay in memory and reset on restart; set `EXCALIDRAW_DATA_DIR` for atomic local persistence across restarts. Note that Mermaid conversion and `set_viewport` still require an open browser tab, while MCP file reads and writes stay sandboxed inside `EXCALIDRAW_EXPORT_DIR`.
Install & configure
Requirements
- Node.js >= 20
- Optional Docker runtime for separate canvas and stdio MCP containers
- Open browser tab at http://127.0.0.1:3000 only when using Mermaid conversion, viewport controls, or live viewing
npx -y mcp-excalidraw-serverAdd `npx -y mcp-excalidraw-server` under `mcpServers` for Claude Desktop, Cursor, or Antigravity, or run `claude mcp add excalidraw --scope user -- npx -y mcp-excalidraw-server`. Coding agents can alternatively install the CLI skill via `npx -y mcp-excalidraw-server install-skill --dir <dir>`.
Examples are translated from the published configuration. Supply your own credentials and verify requirements in the upstream README. Remote connectors are shown only where a supported configuration format is known.
Config file · macOS: ~/Library/Application Support/Claude/claude_desktop_config.json
Windows: %APPDATA%\Claude\claude_desktop_config.json
Use Settings → Developer → Edit Config when available. Do not assume a Linux configuration path; check the client documentation for your platform. Remote servers use the app’s connector flow when supported, not the local stdio file shown here. Merge this example with existing settings; do not overwrite unrelated servers.
{
"mcpServers": {
"excalidraw": {
"command": "npx",
"args": [
"-y",
"mcp-excalidraw-server"
]
}
}
}Config file · Project: .cursor/mcp.json
User: ~/.cursor/mcp.json
The project path is relative to the workspace root. The tilde denotes your user home directory. Use Cursor’s MCP settings to confirm which configuration and scope your installed version is reading. Merge this example with existing settings; do not overwrite unrelated servers.
{
"mcpServers": {
"excalidraw": {
"command": "npx",
"args": [
"-y",
"mcp-excalidraw-server"
]
}
}
}Config file · Workspace: .vscode/mcp.json
For user scope, use the “MCP: Open User Configuration” command if available. Do not guess a user configuration path across operating systems, profiles, containers, or remote workspaces; check the client documentation. Merge this example with existing settings; do not overwrite unrelated servers.
{
"servers": {
"excalidraw": {
"type": "stdio",
"command": "npx",
"args": [
"-y",
"mcp-excalidraw-server"
]
}
}
}Config file · macOS/Linux: ~/.codeium/windsurf/mcp_config.json
Windows: %USERPROFILE%\.codeium\windsurf\mcp_config.json
Open the MCP configuration through Windsurf’s settings when possible to confirm the active file. Paths can differ in managed or future releases; check the client documentation if this location is not present. Merge this example with existing settings; do not overwrite unrelated servers.
{
"mcpServers": {
"excalidraw": {
"command": "npx",
"args": [
"-y",
"mcp-excalidraw-server"
]
}
}
}Config file · Project scope: .mcp.json at the repository root
The project file uses mcpServers. For user scope, use claude mcp add --scope user rather than assuming .mcp.json in your home directory is the user configuration. Check the client documentation for managed settings and storage details. Merge this example with existing settings; do not overwrite unrelated servers.
{
"mcpServers": {
"excalidraw": {
"type": "stdio",
"command": "npx",
"args": [
"-y",
"mcp-excalidraw-server"
]
}
}
}Examples are translated from the published configuration. Supply your own credentials and verify requirements in the upstream README. Remote connectors are shown only where a supported configuration format is known.
Tools
Source: repository README. Tool descriptions are a documented snapshot, not a live capability check.
| Tool | What it does |
|---|---|
| create_element | Adds a single Excalidraw shape, text, arrow, or frame element to the live canvas. |
| batch_create_elements | Creates multiple diagram shapes and bound arrows in a single call. |
| get_element | Reads detailed properties for a specific element ID on the canvas. |
| update_element | Modifies position, styling, text, or metadata on an existing element. |
| delete_element | Removes an element from the active Excalidraw scene. |
| query_elements | Filters elements on the canvas by type, bounding box, or typed attribute matches. |
| duplicate_elements | Clones selected elements on the canvas for repeatable diagram components. |
| align_elements | Aligns multiple elements along edges or centers to clean up diagram geometry. |
| distribute_elements | Distributes spacing evenly across a set of diagram elements. |
| group_elements | Groups element IDs together using native canvas groupIds. |
| ungroup_elements | Ungroups previously grouped elements across sessions. |
| describe_scene | Returns an AI-readable structured text summary of element IDs, coordinates, labels, and arrow connections. |
| get_canvas_screenshot | Renders a deterministic headless PNG screenshot inside the canvas server so agents can inspect overlaps and labels. |
| get_selection | Returns currently selected element IDs and count from the active browser tab. |
| export_scene | Exports deterministic `.excalidraw`, `.json`, or Obsidian `.excalidraw.md` files inside `EXCALIDRAW_EXPORT_DIR`. |
| import_scene | Imports `.excalidraw`, `.json`, Obsidian `.excalidraw.md`, or embedded-scene `.png` diagrams onto the canvas. |
| export_to_image | Exports the diagram or a specific frame/subset to PNG or SVG with dark mode, scale, and optional embedded scene. |
| export_to_excalidraw_url | Uploads an AES-GCM encrypted scene to excalidraw.com (or a self-hosted backend) and returns a shareable link. |
| create_from_mermaid | Converts Mermaid syntax into editable Excalidraw elements merged onto the canvas (requires an open browser tab). |
| snapshot_scene | Saves a named server-side scene checkpoint for rollback via `restore_snapshot`. |
Use cases
- Generate architecture diagrams in Claude Code or Cursor, verify legibility via headless screenshots, and commit byte-stable `.excalidraw` files.
- Export Obsidian-compatible `.excalidraw.md` diagrams directly into a knowledge vault without breaking block references.
- Create README-ready `.excalidraw.png` images with embedded scene data so visuals stay re-importable and editable.
- Render committed `.excalidraw` diagrams offline in CI pipelines via `npx -y mcp-excalidraw-server render`.
Strengths
- Headless PNG and SVG rendering lets agents visually inspect and fix overlapping labels without opening a browser.
- Zero API keys required; runs locally under MIT with auto-started canvas server and optional `EXCALIDRAW_DATA_DIR` persistence.
- Supports CLI + Agent Skill, 27 stdio MCP tools (MCP 2026-07-28 and legacy), REST API, and self-hosted share backends.
Limitations
- Mermaid diagram conversion (`create_from_mermaid`) and `set_viewport` still require an open browser tab.
- Canvas state is in-memory by default and clears on restart unless `EXCALIDRAW_DATA_DIR` is configured.
- Canvas HTTP/WebSocket server has no built-in authentication and should stay bound to `127.0.0.1` (or accessed over SSH tunnel) on untrusted networks.
mcp_excalidraw setup notes
- mcp_excalidraw's stdio example needs a client that launches local processes.