# diagonaldiagrams

> diagonaldiagrams is an open-source MCP server for design and media. Agents draw Mermaid, JSON or CSV as SVG and get an audit for overlaps before showing it. It runs locally on your machine and is started by your AI client.

- **Kind:** MCP server
- **Pricing:** Open source
- **Platforms:** CLI
- **Website:** https://lucas19919.github.io/diagonaldiagrams/
- **Repository:** https://github.com/lucas19919/diagonaldiagrams
- **MCP Registry name:** io.github.lucas19919/diagonaldiagrams
- **Categories:** design and media, developer tools
- **Listing updated:** 2026-11-15

## About

The key idea is that an agent should read one line of JSON rather than a screenshot. After laying out and saving an SVG, the tool checks for text on top of text, arrows through boxes and words that spill out of their shapes, and reports either all clear or each problem with a suggested fix. It is a Python library and command line as well as an MCP server, and needs Python 3.11 or newer.

Input can be Mermaid flowcharts, sequence diagrams and ER diagrams, JSON specs for flow, architecture, sequence and schema figures, an isometric layer stack, and CSV for bar, line and scatter charts. A geo command places points on a built-in coastline, and a generic chart command covers about 60 more types. Extras include a fit option for READMEs, multi-view stories that can be filmed as a GIF with ffmpeg, JSON-patch edits, and export to PNG, PDF, draw.io or Excalidraw.

The project publishes its own benchmark against Mermaid CLI and Pele dated 19 October 2026, and its README cautions that the token comparison rests on two runs. It runs through uvx or a Claude Desktop .mcpb bundle.

## Features

- **Audited SVG output:** Checks overlapping text, arrows through boxes and text that does not fit.
- **One-line JSON verdict:** Reports ok or the errors with a fix, so no screenshots are needed.
- **Mermaid and JSON input:** Flowcharts, sequence and ER diagrams plus JSON specs and CSV charts.
- **Many chart types:** Bar, line, scatter, geo, isometric stacks and about 60 more.
- **Export formats:** PNG, PDF, draw.io and Excalidraw files.
- **Spec editing:** apply edits a figure spec using a JSON patch.

## Good for

- Draw an architecture diagram from a text description
- Turn CSV data into a chart for a README
- Produce a sequence diagram without screenshot checking
- Export a diagram to Excalidraw or draw.io
- Film a multi-view figure as a GIF

## Install

### Claude Code (Terminal)

```sh
claude mcp add diagonaldiagrams -- uvx diagonaldiagrams
```

### Claude Desktop (claude_desktop_config.json)

```json
{
  "mcpServers": {
    "diagonaldiagrams": {
      "command": "uvx",
      "args": [
        "diagonaldiagrams"
      ]
    }
  }
}
```

### Cursor (~/.cursor/mcp.json)

```json
{
  "mcpServers": {
    "diagonaldiagrams": {
      "command": "uvx",
      "args": [
        "diagonaldiagrams"
      ]
    }
  }
}
```

### VS Code (.vscode/mcp.json)

```json
{
  "servers": {
    "diagonaldiagrams": {
      "type": "stdio",
      "command": "uvx",
      "args": [
        "diagonaldiagrams"
      ]
    }
  }
}
```

### Windsurf (~/.codeium/windsurf/mcp_config.json)

```json
{
  "mcpServers": {
    "diagonaldiagrams": {
      "command": "uvx",
      "args": [
        "diagonaldiagrams"
      ]
    }
  }
}
```

### Other clients (your client's MCP settings (most use this shape))

```json
{
  "mcpServers": {
    "diagonaldiagrams": {
      "command": "uvx",
      "args": [
        "diagonaldiagrams"
      ]
    }
  }
}
```

## FAQ

### What does it need?

Python 3.11 or newer; MCP use also needs uv.

### How do I add it to an MCP client?

Use command uvx with args diagonaldiagrams and mcp.

### What does the check catch?

Text over text, arrows through boxes and words that do not fit their shape.

### How does it compare to Mermaid CLI?

On its own 2026-10-19 benchmark a 20-step flowchart took 152 ms against 2,340 ms for Mermaid CLI.

### Where do I install it from?

pip install diagonaldiagrams, a Claude Code plugin, or a .mcpb file for Claude Desktop.

### Is diagonaldiagrams free?

Yes. diagonaldiagrams is open source, so you can use and self-host it for free.

### How do I add diagonaldiagrams to Claude Code?

Run this command in your terminal: claude mcp add diagonaldiagrams -- uvx diagonaldiagrams

### What are the best alternatives to diagonaldiagrams?

The closest alternatives to diagonaldiagrams are REA, HyperFrames by HeyGen, Codebase Memory, GitHub and Serena MCP: the IDE for your agent.

## Alternatives

- [REA](https://ai-powered.com/mcp/rea): REA is an open-source MCP server for developer tools.
- [HyperFrames by HeyGen](https://ai-powered.com/mcp/hyperframes-by-heygen): HyperFrames by HeyGen is a freemium MCP server for design and media.
- [Codebase Memory](https://ai-powered.com/mcp/codebase-memory): Codebase Memory is an open-source MCP server for knowledge and memory.
- [GitHub](https://ai-powered.com/mcp/github-2): GitHub is an open-source MCP server for developer tools.
- [Serena MCP: the IDE for your agent](https://ai-powered.com/mcp/serena-mcp-the-ide-for-your-agent): Serena MCP: the IDE for your agent is an open-source MCP server for developer tools.
- [XERJ](https://ai-powered.com/mcp/xerj): XERJ is an open-source MCP server for knowledge and memory.
- [ffmpeg-skill](https://ai-powered.com/mcp/ffmpeg-skill): ffmpeg-skill is an open-source MCP server for design and media.
- [Ouroboros](https://ai-powered.com/mcp/ouroboros): Ouroboros is an open-source MCP server for developer tools.

---
Source: https://ai-powered.com/mcp/diagonaldiagrams
