drafty
Metabase logo

Build a Metabase dashboard with Claude

Connect the Metabase MCP server to Claude, ask a BI question in plain language, and publish the answer as a self-contained dashboard your team comments on directly — no exporting to a slide, no screenshots pasted into Slack.

What you'll build
A self-contained executive dashboard — weekly active users, signups, conversion to paid, top tables by query volume, and a 12-week trend — generated by Claude from a question you ask in plain language against your real Metabase instance, then published to a drafty.im/canvas/… link. Your team clicks the exact chart or number they want changed and leaves a note. Claude reads the comments and ships a revised version to the same URL.

This is an end-to-end example: connect a BI tool over MCP, turn a question into a dashboard from live numbers, and close the review loop on one link. Total time, start to shared link, is under fifteen minutes. The same shape works for any of the other examples — only the connection step changes.

Here's the finished dashboard, published to a canvas — click any tile or chart to leave a comment, exactly as your team would:

Live canvas — comment on any elementOpen ↗

The three moving parts

  1. The Metabase MCP server gives Claude read access to your Metabase — tables, metrics, saved questions, dashboards, collections — through a controlled set of tools, all scoped to your own Metabase permissions. You can't see anything through Claude that you couldn't already see in Metabase.
  2. Claude asks the questions, runs the queries, and writes a single self-contained HTML dashboard. You iterate on it in the artifact panel until it's right.
  3. Drafty turns that HTML into a stable link your team reviews. Comments pin to the exact element; Claude ships the fix to the same URL.

The generation step is fast now. The part this example is really about is the third one — getting the answer in front of people without losing their feedback to a screenshot circled in Preview.

Step 1 — Connect the Metabase MCP server

Metabase ships an official MCP server built into the platform, served at /api/metabase-mcp on your own instance. An admin enables it once under Admin → AI → MCP (toggle the MCP server on). It uses Streamable HTTP and authenticates over OAuth 2.0 — Metabase runs its own embedded OAuth server, so no key is pasted into a config file.

In Claude Code (swap in your Metabase URL):

claude
claude mcp add --transport http metabase https://your-metabase.example.com/api/metabase-mcp

Then run /mcp inside Claude Code and follow the OAuth prompt to authorize. The connection inherits your Metabase permissions — you only need read access to the collections and tables this dashboard touches.

In Claude Desktop: open Settings → Connectors → Add custom connector, paste https://your-metabase.example.com/api/metabase-mcp, and authorize over OAuth the same way.

Safety first
The MCP server is scoped to the connecting user's existing Metabase permissions — you cannot grant Claude access beyond what your own account can already see. For a reporting dashboard, sign in (or use a service account) with a read-only role limited to the collections you need. There's no key to commit; OAuth handles the handshake. The dashboard only reads — it never needs to create or edit questions.

Step 2 — Pull the numbers

Ask Claude in plain language. It uses the MCP server's read tools (search, read_resource, construct_query, execute_query) to find the right tables and saved questions, then run them:

claude
Using the Metabase MCP server, answer this for a product health dashboard: weekly active users for the last 12 weeks, total signups and paid conversions in the last 30 days vs. the prior 30, current paid conversion rate, and the top 5 tables or saved questions by query volume. Search for the relevant existing metrics or saved questions first and reuse them where they exist, then summarize the figures before you build anything.

Claude searches Metabase, reuses your existing metrics where it can, runs the queries, and returns the figures. Sanity-check them against the matching saved questions in Metabase before going further. This is the moment to catch a wrong assumption — a stale definition of "active," a timezone offset, a filter you didn't expect — while it's cheap.

Step 3 — Build the dashboard

Once the numbers look right, ask for the artifact:

claude
Build a single self-contained HTML dashboard from those figures. Weekly active users as a 12-week line chart hero, then tiles for signups, paid conversions, and conversion rate with their period-over-period change, and a table of the top tables by query volume at the bottom. Clean, no external dependencies — inline the CSS and any chart code.

Claude renders it live in the artifact panel. Iterate in place — you're not regenerating from scratch:

Step 4 — Publish to Drafty for review

A Claude artifact link is a preview, not a stable URL — iterate the artifact and the link you already sent now shows the old version. Ask Claude to publish it to a Drafty canvas instead, so the link you share always stays current:

claude
Publish this dashboard to Drafty as a canvas and give me the shareable link.

Claude pushes the dashboard and hands back a drafty.im/canvas/… link that renders on any device. Send it — your team opens it in a browser, no login and no Claude account needed.

Step 5 — The review loop

This is the part that's not obvious until you've done it once.

A reviewer clicks the specific tile, chart, or number they want changed and leaves a pinned comment — "this WAU count looks low, are we filtering out internal accounts?" The comment is anchored to that element, not floating in a Slack thread. Claude reads the comments through the CLI, reruns the relevant Metabase query if needed, and pushes a revised dashboard to the same URL. The reviewer refreshes and sees the change; the thread stays attached to the element.

The mechanic matters because of what it removes. A Slack message about a chart produces "the number on the left looks wrong." A pinned comment on the actual tile produces "this — exclude internal accounts from the active-user count." One of those produces a correct revision; the other produces a guess.

Keeping it fresh

An MCP-generated dashboard is a snapshot — it holds the numbers Claude pulled when it built it; it doesn't re-query Metabase when someone opens the link. For a weekly review or a board-ready snapshot, that's fine.

To make it a live canvas that always shows today's figures, copy this prompt — Claude sets up the refresh for you and schedules it to run on its own:

claude
Turn this Metabase dashboard into a live canvas: every morning, re-run the same questions against Metabase via the MCP server, rebuild the dashboard, and push a new version to the same canvas URL so the link always shows today's figures. Schedule it to run daily on its own.

The link stays stable while the content updates underneath it — see keeping a canvas updated automatically.

What to watch for

Metabase dashboard with Claude — FAQ

Do I need to paste a Metabase API key or password anywhere?
No. Metabase's built-in MCP server at /api/metabase-mcp authenticates over OAuth 2.0 using its own embedded OAuth server, so you authorize through a consent screen instead of pasting a key into a config file. An admin enables the server once under Admin → AI → MCP; after that, each user connects with their own account.
Is the dashboard live or a snapshot?
A snapshot. It contains the numbers Claude pulled when it built the file; it does not re-query Metabase when someone opens the link. To refresh it, ask Claude to re-run the questions and re-push to the same URL — or put that on a daily schedule so the stable link always shows current numbers.
Can my team comment without a Metabase or Claude account?
Yes. The dashboard is published to a Drafty canvas link that renders in any browser. Reviewers click the exact element they want changed and leave a pinned comment with no login required. Only the person connecting Metabase needs a Metabase account.
Is it safe to give Claude access to my Metabase?
The MCP server is scoped to the connecting user's existing Metabase permissions — you cannot grant Claude access to anything your own account can't already see. Connect with a read-only role limited to the collections you need, and a reporting dashboard never needs more than that. Every tool call is mediated by the MCP server, and in Claude you approve actions.
How is this different from a native Metabase dashboard?
A native Metabase dashboard queries live data against questions you maintain — the right choice for governed, always-current reporting inside the tool. This approach is for a fast, shareable snapshot you can spin up by asking a question in plain language, restyle by talking to Claude, and collect anchored feedback on outside Metabase — for people who don't have a Metabase login. Different jobs: one is a standing system, the other is a quick reviewable deliverable.