home / mcp / data visualization mcp server

Data Visualization MCP Server

Provides an interface to save data tables and render Vega-Lite visualizations via MCP tools.

Installation
Add the following to your MCP client configuration file.

Configuration

View docs
{
  "mcpServers": {
    "isaacwasserman-mcp-vegalite-server": {
      "command": "uv",
      "args": [
        "--directory",
        "/absolute/path/to/mcp-datavis-server",
        "run",
        "mcp_server_datavis",
        "--output_type",
        "png"
      ]
    }
  }
}

You can save structured data tables and render them as Vega-Lite visualizations through a dedicated MCP server. This server exposes two core tools to store data and generate Vega-Lite visualizations, making it easy to iterate on charts directly from your data layer.

How to use

You interact with the server through an MCP client to save data tables and then visualize them using Vega-Lite specifications. Start by saving a data table with a descriptive name, then request a Vega-Lite visualization by passing the table name and a Vega-Lite JSON specification. You can obtain either a text-based Vega-Lite spec as an artifact or a PNG image depending on how you configure the output.

How to install

Prerequisites: ensure you have the MCP runtime available and that the datavis MCP server can be started from your environment. The server example uses a local runtime command to run the MCP server code from a directory.

1. Create a working directory for the Data Visualization MCP server.

2. Place the server code in the directory you created (the exact path is referenced in your start command below).

3. Start the server using the provided runtime command. The example demonstrates using a local runtime to run the MCP server module with a specific output type.

{
  "mcpServers": {
    "datavis": {
      "type": "stdio",
      "name": "datavis",
      "command": "uv",
      "args": [
        "--directory",
        "/absolute/path/to/mcp-datavis-server",
        "run",
        "mcp_server_datavis",
        "--output_type",
        "png"
      ]
    }
  }
}

Additional notes

You will use two main tools exposed by this server. The save_data tool stores a table of data on the server for later visualization, and the visualize_data tool renders that data into a Vega-Lite specification. When you request a visualization, you can choose between a text output containing the Vega-Lite spec or a PNG image embedded as an artifact, depending on the output type you configure in your MCP client.

Tools

save_data saves a data table on the server for later use. Input: name (string) and data (array of objects). Returns a success message.

visualize_data renders a data table using Vega-Lite syntax. Input: data_name (string) and vegalite_specification (string as JSON). Returns a success message with an embedded Vega-Lite spec as an artifact when output_type is text, or a base64 PNG image when output_type is png.

Available tools

save_data

Save a data table to the server for later visualization. Inputs: name (string) for the data table and data (array) representing the data table. Returns a success message.

visualize_data

Create a Vega-Lite visualization from a saved data table. Inputs: data_name (string) referencing the saved table and a Vega-Lite specification as a JSON string. Returns either a text output with the full Vega-Lite spec or a PNG image in base64 depending on the output type.