Excalidraw MCP Server & CLI
A live Excalidraw canvas workbench for AI coding agents to create, edit, and export diagrams programmatically.
- Source repo
- yctimlin/mcp_excalidraw
- Stars
- ★ 2.7k
- Last updated
- 4d ago v2.2.0
- FARS reviewed
- Nov 08, 2026 +1 new
- License
- MIT
- Primary language
- TypeScript
- FA score
- 73/100 · Some gaps
At a glance
- How it runs
- Works with
- Universal · cross-platformChatGPT · Codex · Claude Code · Claude.ai
- Cost
- Free, no paid service needed
- Setup effort
- Low · running in minutes
- You'll need
- Typical use
- An architect uses Claude Code to generate an architecture diagram from a text description and automatically layout the elements.
- Not a fit if
- CI pipelines needing headless screenshots without a browser tab
- Teams needing canvas state to survive a server restart
- Deployments exposed to a network that need built-in authentication
- Website
- mcp-excalidraw-landing.vercel.app ↗ set on GitHub
- Maintenance
- Commits in the last 30 dayslast commit 2026-11-28latest release v2.2.0 (2026-11-10)+3.9 ★/day over 7 days
- Source review
- 73/100 · Some gaps
What does this agent do, and when should you use it?
mcp-excalidraw-server provides AI agents a local canvas server that exposes a programmatic Excalidraw canvas. It offers three interfaces: CLI (recommended for coding agents), MCP server (26 tools), and REST API. Core drawing is fully local, requires no API keys, and only needs Node.js ≥ 18. Agents can create elements, query them, take screenshots, refine layouts iteratively, and export diagrams as .excalidraw files to commit alongside code. The canvas server supports real-time sync and named server-side snapshots. It differs from the official Excalidraw MCP by focusing on a persistent canvas workbench for coding agents, not a one-shot chat widget.
The tool starts a local Excalidraw canvas server (default port 3000) with a REST API and WebSocket real-time sync. Agents can drive the canvas either via CLI commands (add, query, describe, screenshot, export, import, mermaid, snapshot, arrange) or MCP tools (create_element, query_elements, get_canvas_screenshot, export_scene). It can create elements like rectangles with text and arrows, query elements, see the canvas via screenshots, align/distribute/group/lock elements, export to .excalidraw or .excalidraw.md (Obsidian) formats, create diagrams from Mermaid, and save named snapshots. Elements are stored in-memory on the server, so persistence is achieved via export or snapshots. It also provides an optional share command that uploads an encrypted scene to excalidraw.com.
- An architect uses Claude Code to generate an architecture diagram from a text description and automatically layout the elements.
- A developer updates architecture diagrams in documentation after code changes by re-importing and editing .excalidraw files.
- Obsidian users export diagrams as .excalidraw.md files to embed directly into notes with the Obsidian Excalidraw plugin.
- CI pipelines generate diagrams headlessly via CLI as build artifacts, without needing MCP configuration.
- Agents in Cursor or Codex CLI create flowcharts on the fly and iterate with the agent's help.
How do you install or deploy this agent?
Prerequisite: Node.js ≥ 18. No clone or MCP configuration is required; use npx directly. For MCP clients, add the config as per the README. For coding agents, recommended: run npx -y mcp-excalidraw-server install-skill --dir <skills-root>.
How do you use this agent?
1) Start the canvas: npx -y mcp-excalidraw-server start, then open http://127.0.0.1:3000 in a browser to enable screenshots and Mermaid. 2) Add elements: echo '[{"id":"api","type":"rectangle",...}]' | npx -y mcp-excalidraw-server add. 3) Inspect: npx -y mcp-excalidraw-server describe and screenshot. 4) Export: npx -y mcp-excalidraw-server export --out docs/architecture.excalidraw. The CLI auto-starts the server if needed.
Safety boundaries, hardening & integrations
Operational blast radius, source-verified safety controls, and first-run hardening steps before connecting this agent to real workspaces.
Declared capability surface (blast radius)
Can run terminal commands; pair with approval gates or container/OS sandboxing.
Modifies local files; work on a clean Git branch or dedicated worktree.
Makes outbound requests; verify telemetry settings and model data routing on private repos.
What are this agent's strengths and limitations?
- Element-level CRUD and layout tools (align, distribute, group, lock) far beyond the official MCP's capabilities.
- Screenshot and structured text descriptions let agents self-verify and fix layout issues.
- Fully local, no API keys, MIT licensed, and free to use.
- Offers CLI, MCP, and REST interfaces, making it usable from many agents and frameworks.
- Canvas state is stored in-memory and lost on server restart; requires explicit export or snapshots.
- Screenshots, image export, and Mermaid conversion require a browser tab open to the canvas URL; not headless.
- Docker setup requires network configuration (e.g., host.docker.internal) and the Docker MCP image cannot auto-start the canvas server.
How does this agent compare with similar options?
Compared to the official Excalidraw MCP, this project provides a persistent canvas with fine-grained control (element CRUD, layout tools, screenshot feedback), whereas the official one is a one-shot chat widget with only two tools.
Key facts side by side with the most closely related agents.
| Agent | Source review | Form / cost | Stars | Updated | Language | Full support on |
|---|---|---|---|---|---|---|
| Excalidraw MCP Server & CLI This agent | 73 · Some gaps | CLIFree | ★ 2.7k | 4d ago | TypeScript | ChatGPT · Codex · Claude Code · Claude.ai |
| Cambium | 85 · Good | CLIFree | ★ 663 | 2mo ago | Python | Codex · Claude Code |
| REA: Reverse Engineer Anything with Agents | 84 · Good | CLIFree | ★ 487k | today | TypeScript | Codex · Claude Code · Claude.ai |
| Uni-CLI | 83 · Good | CLIFree | ★ 229 | 1mo ago | TypeScript | ChatGPT · Codex · Claude Code |
How does FollowAgents rate this agent?
Why each dimension lost points
The server defaults to 127.0.0.1, file tools are described as restricted by extension and export directory, clearing requires explicit --yes, and snapshots can be restored. These support ordinary-use scores for least privilege, external-effect control, and rollback. The README discloses that share uploads an encrypted scene and that the API has no built-in authentication when exposed on a network interface. Deductions: ordinary write operations do not require per-action confirmation, CORS is open, and authorization boundaries for the API and WebSocket are unclear in the supplied source. Dependencies and versions are listed, but no security audit or vulnerability response evidence is provided. Author, repository, and MIT license are stated, but publisher identity is not verified by the curated registry and earns no identity-based credit.
The README, skill, and package scripts broadly agree on CLI, MCP, REST, and the local canvas; source excerpts show error statuses, input validation, and MCP startup error output. Deductions: several protocol, rendering-stability, and compatibility benefits are asserted mainly in the README and cannot be independently established from the supplied material; the font CDN and npm/npx installation also create external availability dependencies.
The skill clearly names tasks and trigger scenarios and covers MCP, CLI, REST, and several agent/client environments. It states that Mermaid conversion and viewport control need a browser tab, raw REST has stricter payloads, and the remote canvas URL is not an HTTP MCP endpoint. Environment guidance covers Node 20+, containers, offline rendering, and SSH tunneling. Deductions: browser-dependent capabilities remain limited, and some workflows depend on scripts and network services.
The README provides a contents list, per-interface installation guidance, CLI reference, configuration table, FAQ/troubleshooting/known-issues sections, examples, and development notes; package version, change summaries, and MIT license are clear. Deductions: the supplied material does not show a maintenance owner or support policy, the change history covers only selected releases, and author metadata offers limited maintenance commitment; two CLI names and multiple MCP/CLI/REST entry points add slight naming complexity.
The product offers an editable canvas, element-level operations, live sync, structured descriptions, screenshots, import/export, snapshots, and Mermaid conversion. Outputs can be used as repository or Obsidian files, while CLI/MCP/REST provide useful integration paths. Deductions: installation and use require Node and a canvas service, and sharing, fonts, and first-run npx add external dependencies; actual output quality and runtime stability were not established by this static review.
Many README feature claims have corresponding pointers in the skill, package scripts, or source interfaces, and the CI workflow lists build, type-check, and check scripts. Deductions: these files establish that checks are configured, not that this revision passed CI; rendering determinism, performance, and compatibility are mostly project claims, and the material does not consistently distinguish claims from inference.
- When binding the canvas to a network interface, the project says the API has no built-in authentication; apply access controls at the network layer.
- The share feature uploads an encrypted scene to the configured service; consider whether that is suitable for diagrams containing sensitive content.
- This is a low-confidence static review; CI configuration and project claims do not substitute for running this revision.
Recent releases
Latest entries from the project's GitHub Releases. Notes are quoted from upstream as written, not rewritten or tested by FollowAgents.
-
Release notes excerpt
Features - Act on the selection: get_selection (MCP) and selection (CLI) return the IDs selected in the most recently active canvas tab. (#149, thanks @Totopo27; requested in #147 by @fgeierst) - Editable PNGs: export a PNG with the scene embedded (--embed-scene / embedScene: true, PNG only, off by default) and import or render it later. One .excalidraw.png file is both the README preview and the editable source. (#132, thanks @FortniteGamer747) …View on GitHub ↗ -
Release notes excerpt
Fixes - Snapshot restore and import are atomic: a rejected restore or replace-import no longer wipes the canvas. Native frames now restore, import, export and can be created through the CLI and MCP. (#101, thanks @sanjayy0612; #120) - One label per shape: updating or renaming a labelled shape while a canvas tab is open no longer stacks duplicate labels. (#121, thanks @sdrshn-nmbr) - Dropped images survive reload: the tab uploads image files on sync (only new ones), so they persist and appear in exports and headless screenshots. (#122, thanks @appdesigngeeks) …View on GitHub ↗ -
Release notes excerpt
Fixes - Exports always load: valid order keys, so saved scenes with more than about 45 labelled shapes no longer fail with invalid order key. Free text exports left/top aligned, like the canvas. (#115, thanks @fernandovmacedo) - No more drift on sync: center- and right-aligned text, labels on arrows, and arrows no longer move or shrink each time an open canvas tab syncs. Text x/y is always the top-left corner. (#116, thanks @hidinginabunker) …View on GitHub ↗
FAQ
Does it need an API key or cloud service?
Are diagrams persistent?
Why do I need a browser?
Which AI tools are supported?
Thanks — we use this to improve the page.
Subscribe to the FollowAgents RSS feed, or save this agent to your browser shortlist to compare on your next visit.