trackmcp
Back to directory
hustcc

mcp-echarts

View on GitHub

๐Ÿงฌ Generate visual charts using ECharts with AI MCP dynamically, used for chart generation and data analysis. TypeScript-based implementation.

129 stars TypeScriptAI & Machine Learning Updated Oct 19, 2025
echartsllmmcpmcp-server

Documentation

MCP ECharts ! ![build](https://github.com/hustcc/mcp-echarts/actions/workflows/build.yml) ![npm Version](https://www.npmjs.com/package/mcp-echarts) ![Listed on Skillselion](https://skillselion.com/mcp/tool/io.github.hustcc/mcp-echarts) ![npm License](https://www.npmjs.com/package/mcp-echarts) ![Trust Score](https://archestra.ai/mcp-catalog/hustcc__mcp-echarts)

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

Prerequisites

  • Node.js 18 or higher is required.

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, skillselion.com 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

    3. 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.

    Frequently asked questions

    What is mcp-echarts?

    mcp-echarts is ๐Ÿงฌ Generate visual charts using ECharts with AI MCP dynamically, used for chart generation and data analysis. TypeScript-based implementation.

    How do I install mcp-echarts?

    Open the GitHub repository and follow its README. Most MCP servers are added to your client's MCP config, then called by your agent.

    Is mcp-echarts open source?

    Yes โ€” it is hosted on GitHub at https://github.com/hustcc/mcp-echarts and has 129 stars.

    Related MCP tools

    Run your own MCP server? See who uses it and what to fix.

    Measure it with TrackMCP