MCP ECharts

MCP ECharts

Dynamically generate Apache ECharts visualizations via Model Context Protocol (MCP).

153
Stars
29
Forks
153
Watchers
6
Issues
MCP ECharts enables dynamic generation of Apache ECharts visualizations through the Model Context Protocol, supporting interactions with AI models. It provides multiple transport options (stdio, SSE, streamable) and integrates with platforms like Claude, VSCode, and Smithery. The tool allows exporting charts in PNG, SVG, and option formats, with optional MinIO storage for enhanced sharing and performance. Featuring zero dependencies and local secure rendering, it is easily deployable and versatile for a range of visualization workflows.

Key Features

Full support for all Apache ECharts features and syntax
Exports charts as PNG, SVG, or ECharts option formats
Multiple transport protocols: stdio, SSE, and streamable
Desktop application integration for model-based scenarios
MinIO support to store charts and share via URLs
Zero external dependencies for lightweight installation
Secure, local chart generation without remote calls
ECharts validation for multi-round model output correction
Customizable CLI options for flexible deployment
Compatibility with various AI model platforms like Claude and Smithery

Use Cases

Dynamically generating data visualizations from AI assistant outputs
Integrating chart rendering into desktop AI and code editors
Automating creation and export of ECharts-based infographics
Embedding AI-powered chart services in web or SaaS platforms
Storing and sharing charts via object storage for collaboration
Prototyping data-driven dashboards in AI development environments
Streamlining model-driven data analysis workflows
Enabling high-performance, local chart rendering in secure environments
Validating and correcting AI-generated chart syntax
Batch chart generation and export for reporting or analytics pipelines

README

MCP ECharts build npm Version smithery badge npm License Trust Score

Generate Apache ECharts with AI MCP dynamically for chart generation and data analysis. Also you can use mcp-server-chart to generate chart, graph, map.

✨ Features

  • Fully support all features and syntax of ECharts, include data, style, theme and so on.
  • Support exporting to png, svg, and option formats, with validation for ECharts to facilitate the model's multi-round output of correct syntax and graphics.
  • MinIO Integration, store charts in MinIO object storage and return URLs instead of Base64 data for better performance and sharing capabilities.
  • Lightweight, we can install it easily with zero dependence.
  • Extremely secure, fully generated locally, without relying on any remote services.

🤖 Usage

Desktop Applications (stdio transport)

To use with Desktop APP, such as Claude, VSCode, Cline, Cherry Studio, and so on, add the MCP server config below. On Mac system:

json
{
  "mcpServers": {
    "mcp-echarts": {
      "command": "npx",
      "args": [
        "-y",
        "mcp-echarts"
      ]
    }
  }
}

On Window system:

json
{
  "mcpServers": {
    "mcp-echarts": {
      "command": "cmd",
      "args": [
        "/c",
        "npx",
        "-y",
        "mcp-echarts"
      ]
    }
  }
}

Also, you can use it on modelscope, glama.ai, smithery.ai or others with HTTP, SSE Protocol.

🚰 Run with SSE or Streamable transport

Install the package globally.

bash
npm install -g mcp-echarts

Run the server with your preferred transport option:

bash
# For SSE transport (default endpoint: /sse)
mcp-echarts -t sse

# For Streamable transport with custom endpoint
mcp-echarts -t streamable

Then you can access the server at:

  • SSE transport: http://localhost:3033/sse
  • Streamable transport: http://localhost:3033/mcp

🎮 CLI Options

You can also use the following CLI options when running the MCP server. Command options by run cli with -h.

plain
MCP ECharts CLI

Options:
  --transport, -t  Specify the transport protocol: "stdio", "sse", or "streamable" (default: "stdio")
  --port, -p       Specify the port for SSE or streamable transport (default: 3033)
  --endpoint, -e   Specify the endpoint for the transport:
                    - For SSE: default is "/sse"
                    - For streamable: default is "/mcp"
  --help, -h       Show this help message

🗂️ MinIO Configuration (Optional)

For better performance and sharing capabilities, you can configure MinIO object storage to store chart images as URLs instead of Base64 data.

[!NOTE] If MinIO is not configured or unavailable, the system automatically falls back to Base64 data output, ensuring compatibility.

We can Integrate with MinIO object storage providers below.

Also, we can setup MinIO locally for free.

  1. Install and start MinIO locally:

    bash
    # Download MinIO (macOS example)
    brew install minio/stable/minio
    
    # Start MinIO server
    minio server ~/minio-data --console-address :9001
    
  2. Configure environment variables:

    bash
    # Copy the example environment file
    cp .env.example .env
    
    # Edit .env with your MinIO settings
    MINIO_ENDPOINT=localhost
    MINIO_PORT=9000
    MINIO_USE_SSL=false
    MINIO_ACCESS_KEY=minioadmin
    MINIO_SECRET_KEY=minioadmin
    MINIO_BUCKET_NAME=mcp-echarts
    

🔨 Development

Install dependencies:

bash
npm install

Build the server:

bash
npm run build

Start the MCP server:

bash
npm run start

🧑🏻‍💻 Contributors

  • lyw405: Supports 15+ charting MCP tool. #2
  • 2niuhe: Support MCP with SSE and Streaming HTTP. #17
  • susuperli: Use MinIO to save the chart image base64 and return the url. #10
  • BQXBQX: Use @napi-rs/canvas instead node-canvas. #3
  • Meet-student: Add outputType schema for all chart tools. #24
  • hustcc: Initial the repo.

📄 License

MIT@hustcc.

Star History

Star History Chart

Repository Owner

hustcc
hustcc

User

Repository Details

Language TypeScript
Default Branch main
Size 10,004 KB
Contributors 9
License MIT License
MCP Verified Nov 11, 2025

Programming Languages

TypeScript
95.38%
JavaScript
4.41%
Dockerfile
0.18%
Shell
0.03%

Tags

Topics

echarts llm mcp mcp-server

Join Our Newsletter

Stay updated with the latest AI tools, news, and offers by subscribing to our weekly newsletter.

We respect your privacy. Unsubscribe at any time.

Related MCPs

Discover similar Model Context Protocol servers

  • MCP Mermaid

    MCP Mermaid

    AI-powered dynamic generation of Mermaid diagrams via the Model Context Protocol.

    MCP Mermaid enables dynamic generation of Mermaid diagrams and charts using AI via the Model Context Protocol (MCP). It supports all features and syntax of Mermaid, and can export diagrams in various formats including SVG, base64, and files. The server can be run locally or globally using different transport protocols such as stdio, SSE, or streamable, making it compatible with tools like Claude, VSCode, and Smithery. It provides customization for background color and theme, and validates output to ensure correct syntax and graphics.

    • 283
    • MCP
    • hustcc/mcp-mermaid
  • Data Visualization MCP Server

    Data Visualization MCP Server

    MCP server for data visualization using Vega-Lite.

    Data Visualization MCP Server enables large language models to visualize data through a standardized interface using Vega-Lite specifications. The server provides tools for saving data tables and generating visualizations as text or PNG images. Integration with platforms like Claude Desktop allows seamless addition of data visualization capabilities to LLM workflows.

    • 92
    • MCP
    • isaacwasserman/mcp-vegalite-server
  • Qlik MCP Server

    Qlik MCP Server

    Connect Claude AI to Qlik Cloud applications and extract insights via the Model Context Protocol.

    Qlik MCP Server enables integration between Claude AI and Qlik Cloud applications through the Model Context Protocol (MCP). It exposes API tools for listing Qlik apps, retrieving sheets and charts, and extracting chart data programmatically. The server supports deployment via Docker, Deno, or Node.js, and can be configured for use with tools like Claude Desktop and Cursor. The setup emphasizes secure handling of Qlik Cloud credentials and flexible environment configuration.

    • 7
    • MCP
    • jwaxman19/qlik-mcp
  • Markmap MCP Server

    Markmap MCP Server

    Convert Markdown to interactive mind maps via the Model Context Protocol.

    Markmap MCP Server enables seamless conversion of Markdown content into interactive mind maps using the Model Context Protocol (MCP). It leverages the open-source markmap project and provides users with diverse export formats including PNG, JPG, and SVG. Designed for easy integration with MCP clients, it offers tools for automated browser previews, rich interactivity, and batch mind map generation. The server can be installed easily via npm or Smithery and supports configurable output directories.

    • 137
    • MCP
    • jinzcdev/markmap-mcp-server
  • Mindpilot MCP

    Mindpilot MCP

    Visualize and understand code structures with on-demand diagrams for AI coding assistants.

    Mindpilot MCP provides AI coding agents with the capability to visualize, analyze, and understand complex codebases through interactive diagrams. It operates as a Model Context Protocol (MCP) server, enabling seamless integration with multiple development environments such as VS Code, Cursor, Windsurf, Zed, and Claude Code. Mindpilot ensures local processing for privacy, supports multi-client connections, and offers robust configuration options for server operation and data management. Users can export diagrams and adjust analytics settings for improved user control.

    • 61
    • MCP
    • abrinsmead/mindpilot-mcp
  • Mindmap MCP Server

    Mindmap MCP Server

    Convert Markdown content into interactive mindmaps via an MCP-compliant server.

    Mindmap MCP Server provides a Model Context Protocol (MCP) compatible service that transforms Markdown input into interactive mindmap visualizations. It supports command-line, Python, and Docker installation methods for flexibility across platforms. Designed to integrate with MCP clients like Claude Desktop, it ensures seamless Markdown-to-mindmap conversion using markmap under the hood. The server is intended for easy plug-and-play use in model-powered workflows that require structured, visual context formatting.

    • 205
    • MCP
    • YuChenSSR/mindmap-mcp-server
  • Didn't find tool you were looking for?

    Be as detailed as possible for better results