Metabase
Metabase includes a built-in Model Context Protocol (MCP) server that lets AI clients connect directly to a Metabase instance. It uses the Streamable HTTP transport and builds on Metabase's Agent API to expose tools for searching, exploring, querying
What is Metabase?
Metabase is a Model Context Protocol (MCP) server that allows AI assistants like Claude, Cursor, and VS Code to metabase includes a built-in model context protocol (mcp) server that lets ai clients connect directly to a metabase instance. it uses the streamable http transport and builds on metabase's agent api ...
Metabase includes a built-in Model Context Protocol (MCP) server that lets AI clients connect directly to a Metabase instance. It uses the Streamable HTTP transport and builds on Metabase's Agent API to expose tools for searching, exploring, querying
This server falls under the Analytics category on MCPgee, the world's largest MCP server directory with 33,000+ servers.
Features
- Metabase includes a built-in Model Context Protocol (MCP) se
Use Cases
Maintainer
Works with
Installation
NPM
npx -y metabaseManual Installation
npx -y metabaseConfiguration
Configuration Details
claude_desktop_config.json
Performance
Response Metrics
Resource Usage
How to Set Up and Use Metabase
The Metabase MCP server connects AI clients like Claude directly to a Metabase analytics instance, enabling natural-language querying, exploration, and export of your business intelligence data. It exposes five unified tools — list, retrieve, search, execute, and export — covering everything from browsing dashboards and cards to running custom SQL queries and exporting up to 1 million rows. With built-in response optimization (up to 90% token reduction), multi-layer caching, and read-only mode enforced by default, it is well-suited for both exploratory data analysis and production BI workflows.
Prerequisites
- Node.js 18.0.0 or higher installed
- A running Metabase instance (cloud or self-hosted) with a valid URL
- A Metabase API key (recommended) or email/password credentials
- An MCP-compatible client such as Claude Desktop or Claude Code
Obtain Metabase credentials
Log in to your Metabase instance and generate an API key under Settings > Admin > API Keys. Note your Metabase instance URL (e.g., https://analytics.example.com). API key authentication is recommended over email/password for security.
Add the server to your MCP client configuration
Open your MCP client config file (claude_desktop_config.json for Claude Desktop) and add the metabase-mcp server entry. Supply the required METABASE_URL and METABASE_API_KEY environment variables.
{
"mcpServers": {
"metabase-mcp": {
"command": "npx",
"args": ["-y", "@jerichosequitin/metabase-mcp"],
"env": {
"METABASE_URL": "https://your-metabase-instance.com",
"METABASE_API_KEY": "your_api_key_here",
"METABASE_READ_ONLY_MODE": "true",
"EXPORT_DIRECTORY": "~/Downloads/Metabase",
"CACHE_TTL_MS": "600000"
}
}
}
}Restart your MCP client
Save the configuration file and restart Claude Desktop (or reload the MCP server in your client). The metabase-mcp server will start automatically via npx on first use, downloading the package if needed.
Verify the connection
In your AI client, ask it to list available Metabase databases or dashboards. A successful response confirms the server is connected and authenticated.
(Optional) Enable write mode for SQL execution
By default, METABASE_READ_ONLY_MODE is true, blocking INSERT, UPDATE, DELETE, and DROP statements. Set it to false only if you need write access via the execute tool.
"METABASE_READ_ONLY_MODE": "false"Metabase Examples
Client configuration
Full claude_desktop_config.json entry for Metabase MCP with API key authentication and default safe settings.
{
"mcpServers": {
"metabase-mcp": {
"command": "npx",
"args": ["-y", "@jerichosequitin/metabase-mcp"],
"env": {
"METABASE_URL": "https://your-metabase-instance.com",
"METABASE_API_KEY": "your_api_key_here",
"METABASE_READ_ONLY_MODE": "true",
"EXPORT_DIRECTORY": "~/Downloads/Metabase",
"CACHE_TTL_MS": "600000",
"LOG_LEVEL": "info"
}
}
}
}Prompts to try
Example prompts that exercise the list, search, execute, and export tools.
- "List all dashboards in my Metabase instance."
- "Search for cards related to revenue in the Sales collection."
- "Run this SQL against database 2: SELECT date_trunc('month', created_at), COUNT(*) FROM orders GROUP BY 1 ORDER BY 1"
- "Retrieve the details of card ID 42 including its query and parameters."
- "Export the results of card 15 to CSV with the date filter set to last 30 days."Troubleshooting Metabase
Authentication error: 401 Unauthorized
Verify that METABASE_URL does not have a trailing slash and that METABASE_API_KEY matches an active key in Metabase Admin > API Keys. If using email/password, set both METABASE_USER_EMAIL and METABASE_PASSWORD instead.
execute tool blocked with 'read-only mode' error
METABASE_READ_ONLY_MODE defaults to true, which blocks any non-SELECT SQL. Set it to false in your config env block to allow write queries, or use only SELECT statements.
Responses are slow or timeouts occur on large datasets
Increase REQUEST_TIMEOUT_MS (default 600000 ms) for very large queries, and use the export tool for datasets over 500 rows rather than the execute tool. Consider lowering CACHE_TTL_MS if cached data seems stale.
Frequently Asked Questions about Metabase
What is Metabase?
Metabase is a Model Context Protocol (MCP) server that metabase includes a built-in model context protocol (mcp) server that lets ai clients connect directly to a metabase instance. it uses the streamable http transport and builds on metabase's agent api to expose tools for searching, exploring, querying It connects AI assistants to external tools and data sources through a standardized interface.
How do I install Metabase?
Install via npm with the command: npx -y metabase. Then add the server configuration to your AI client's JSON config file (e.g., claude_desktop_config.json or .cursor/mcp.json).
Which AI clients work with Metabase?
Metabase works with all major MCP-compatible AI clients including Claude Desktop, Claude Code, Cursor, VS Code (GitHub Copilot), Windsurf, and Cline.
Is Metabase free to use?
Yes, Metabase is open source and available under the MIT License license. You can use it freely in both personal and commercial projects.
Metabase Alternatives — Similar Analytics Servers
Looking for alternatives to Metabase? Here are other popular analytics servers you can use with Claude, Cursor, and VS Code.
OpenMetadata
★ 14.0kOpenMetadata is a unified metadata platform for data discovery, data observability, and data governance powered by a central metadata repository, in-depth column level lineage, and seamless team collaboration.
Superset
★ 10.9kAn MCP server that provides AI assistants with full access to Apache Superset instances, enabling interaction with dashboards, charts, datasets, databases, and SQL execution capabilities.
Horizon
★ 4.4k📡 Your own AI-powered news radar. Generates daily briefings in English & Chinese. | 用 AI 构建你专属的新闻雷达
MCP Server Chart
★ 4.1kEnables generation of 25+ types of charts and data visualizations using AntV, including bar charts, line charts, maps, mind maps, and specialized diagrams like fishbone and sankey charts. Supports both statistical charts and geographic visualizations
Muapi CLI
★ 997Official CLI for muapi.ai — generate images, videos & audio from the terminal. MCP server, 14 AI models, npm + pip installable.
Weather MCP Server
★ 907Weather Data Fetcher MCP server built with Node.js, MCP SDK, and Zod. Provides weather details like temperature and forecast for cities such as Noida and Delhi via a registered tool. Simplifies API integration, enabling structured responses for clien
Browse More Analytics MCP Servers
Explore all analytics servers available in the MCPgee directory. Each server includes setup guides for Claude, Cursor, and VS Code.
Set Up Metabase in Your Editor
Choose your AI client for step-by-step setup instructions.
Quick Config Preview
Add this to your claude_desktop_config.json or .cursor/mcp.json
Ready to use Metabase?
Browse our complete directory of 33,000+ MCP servers, read setup guides for your editor, and start building with the Model Context Protocol.