Datawrapper MCP Server

1

Add it to Claude Code

Run this in a terminal.

Run in terminal
claude mcp add -e "DATAWRAPPER_ACCESS_TOKEN=${DATAWRAPPER_ACCESS_TOKEN}" datawrapper-mcp -- uvx datawrapper-mcp
Required:DATAWRAPPER_ACCESS_TOKEN+ 3 optional
README.md

Create, update, and publish Datawrapper charts through natural language.

A Model Context Protocol (MCP) server that enables AI assistants to create Datawrapper charts. Built on the datawrapper Python library with Pydantic validation.

Example Usage

Here's a complete example showing how to create, publish, update, and display a chart by chatting with the assistant:

"Create a datawrapper line chart showing temperature trends with this data:
2020, 15.5
2021, 16.0
2022, 16.5
2023, 17.0"
# The assistant creates the chart and returns the chart ID, e.g., "abc123"

"Publish it."
# The assistant publishes it and returns the public URL

"Update chart with new data for 2024: 17.2°C"
# The assistant updates the chart with the new data point

"Make the line color dodger blue."
# The assistant updates the chart configuration to set the line color

"Show me the editor URL."
# The assistant returns the Datawrapper editor URL where you can view/edit the chart

"Show me the PNG."
# The assistant embeds the PNG image of the chart in its contained response.

"Suggest five ways to improve the chart."
# See what happens!

Getting Started

Requirements

Get Your API Token

  1. Go to https://app.datawrapper.de/account/api-tokens
  2. Create a new API token
  3. Add it to your MCP configuration as shown below

Installation

Claude Code

Using uvx (recommended)

Configure your MCP client in claude_desktop_config.json:

{
  "mcpServers": {
    "datawrapper": {
      "command": "uvx",
      "args": ["datawrapper-mcp"],
      "env": {
        "DATAWRAPPER_ACCESS_TOKEN": "your-token-here"
      }
    }
  }
}

Using pip

First install the package:

pip install datawrapper-mcp

Then configure your MCP client in claude_desktop_config.json:

{
  "mcpServers": {
    "datawrapper": {
      "command": "datawrapper-mcp",
      "env": {
        "DATAWRAPPER_ACCESS_TOKEN": "your-token-here"
      }
    }
  }
}
OpenAI Codex

CLI with uvx

Add this to ~/.codex/config.toml:

[mcp_servers.datawrapper]
args = ["datawrapper-mcp"]
command = "uvx"
startup_timeout_sec = 30

[mcp_servers.datawrapper.env]
DATAWRAPPER_ACCESS_TOKEN = "your-token-here"

CLI with pip

First install the package:

pip install datawrapper-mcp

Then add this to ~/.codex/config.toml:

[mcp_servers.datawrapper]
command = "datawrapper-mcp"
startup_timeout_sec = 30

[mcp_servers.datawrapper.env]
DATAWRAPPER_ACCESS_TOKEN = "your-token-here"

Secure secrets

For enhanced security, you can configure a pass-through environment variable by ensuring that DATAWRAPPER_ACCESS_TOKEN is set in your environment, and replacing this in your config.toml:

[mcp_servers.datawrapper.env]
DATAWRAPPER_ACCESS_TOKEN = "your-token-here"

With this:

env_vars = ["DATAWRAPPER_ACCESS_TOKEN"]

This ensures that the value set for DATAWRAPPER_ACCESS_TOKEN in your environment is passed through to Codex without having to store the secret as text in a config file.

Desktop application

If you're using the Codex Desktop Application, you can set up the MCP in your settings under MCP servers:

  1. Under Custom servers, click Add server
  2. Under Name, enter datawrapper-mcp
  3. Select STDIO
  4. Under Command to launch, type uvx (you must have uv installed)
  5. Under Arguments, add datawrapper-mcp
  6. Under Environment variables, add DATAWRAPPER_ACCESS_TOKEN as the key and your token as the value
  7. Click Save

Kubernetes Deployment

For enterprise deployments, this server can be deployed to Kubernetes using HTTP transport:

Building the Docker Image
docker build -t datawrapper-mcp:latest .
Running with Docker
docker run -p 8501:8501 \
  -e DATAWRAPPER_ACCESS_TOKEN=your-token-here \
  -e MCP_SERVER_HOST=0.0.0.0 \
  -e MCP_SERVER_PORT=8501 \
  datawrapper-mcp:latest
Environment Variables
  • DATAWRAPPER_ACCESS_TOKEN: Your Datawrapper API token (required)
  • MCP_SERVER_HOST: Server host (default: 0.0.0.0)
  • MCP_SERVER_PORT: Server port (default: 8501)
  • MCP_SERVER_NAME: Server name (default: datawrapper-mcp)
Health Check Endpoint

The HTTP server includes a /healthz endpoint for Kubernetes liveness and readiness probes:

curl http://localhost:8501/healthz
# Returns: {"status": "healthy", "service": "datawrapper-mcp"}
Kubernetes Configuration Example
apiVersion: apps/v1
kind: Deployment
metadata:
  name: datawrappe

Tools (4)

create_chartCreates a new chart in Datawrapper.
update_chartUpdates an existing chart with new data or configuration.
publish_chartPublishes a chart to make it public.
get_chart_imageRetrieves a PNG image of the chart.

Environment Variables

DATAWRAPPER_ACCESS_TOKENrequiredYour Datawrapper API token
MCP_SERVER_HOSTServer host (default: 0.0.0.0)
MCP_SERVER_PORTServer port (default: 8501)
MCP_SERVER_NAMEServer name (default: datawrapper-mcp)

Configuration

claude_desktop_config.json
{"mcpServers": {"datawrapper": {"command": "uvx", "args": ["datawrapper-mcp"], "env": {"DATAWRAPPER_ACCESS_TOKEN": "your-token-here"}}}}

Try it

Create a datawrapper line chart showing temperature trends with this data: 2020, 15.5; 2021, 16.0; 2022, 16.5; 2023, 17.0
Publish the chart I just created.
Update the chart with new data for 2024: 17.2°C
Make the line color of my chart dodger blue.
Show me the PNG image of the chart.

Frequently Asked Questions

What are the key features of Datawrapper MCP?

Create and publish Datawrapper charts via natural language. Update existing charts with new data points. Modify chart visual configurations programmatically. Retrieve chart editor URLs and PNG images. Supports both stdio and HTTP transport for Kubernetes deployment.

What can I use Datawrapper MCP for?

Automating the creation of recurring data reports for journalists. Quickly visualizing datasets during data analysis sessions with an AI. Updating live dashboards with new data points without manual editor interaction. Generating chart previews directly within the AI chat interface.

How do I install Datawrapper MCP?

Install Datawrapper MCP by running: uvx datawrapper-mcp

What MCP clients work with Datawrapper MCP?

Datawrapper MCP works with any MCP-compatible client including Claude Desktop, Claude Code, Cursor, and other editors with MCP support.

Turn this server into reusable context

Keep Datawrapper MCP docs, env vars, and workflow notes in Conare so your agent carries them across sessions.

Need the old visual installer? Open Conare IDE.
Open Conare