drafty
BigQuery logo

Build a BigQuery dashboard with Claude

Connect the BigQuery MCP server to Claude, turn a warehouse query into a dashboard from your live tables, and publish it to a link your team comments on directly — no BI tool, no screenshots pasted into Slack.

What you'll build
A self-contained analytics dashboard — daily active users, revenue trend, top events, conversion funnel, a slow-query watchlist — generated by Claude straight from the SQL it runs against your BigQuery tables, 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 data source over MCP, generate 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 number to leave a comment, exactly as your team would:

Live canvas — comment on any elementOpen ↗

The three moving parts

  1. The BigQuery MCP server gives Claude read access to your warehouse — datasets, table schemas, and SQL it runs against your data — through a controlled set of tools. You approve what it can touch.
  2. Claude writes the SQL, runs it, and turns the result set into 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 dashboard in front of people without losing their feedback to a screenshot circled in Preview.

Step 1 — Connect the BigQuery MCP server

Google's official path is the MCP Toolbox for Databases — an open-source MCP server you run locally with a prebuilt BigQuery toolset. It authenticates over Application Default Credentials (ADC), so no API key or service-account JSON is pasted into a config file — your existing Google Cloud IAM decides what Claude can read.

First, authorize read-only ADC and download the toolbox binary:

claude
gcloud auth application-default login --scopes https://www.googleapis.com/auth/bigquery.readonly,https://www.googleapis.com/auth/cloud-platform

In Claude Code, register the toolbox (swap in your project; --prebuilt bigquery loads the read-focused BigQuery tools):

claude
claude mcp add bigquery --env BIGQUERY_PROJECT=YOUR_PROJECT_ID -- ./toolbox --prebuilt bigquery --stdio

Then run /mcp inside Claude Code to confirm it connected. Sign in as a principal whose IAM grants are read-only — the BigQuery Data Viewer role (roles/bigquery.dataViewer) plus BigQuery Job User to run queries is enough for a reporting dashboard.

In Claude Desktop: open Settings → Developer → Edit Config and add a bigquery entry to mcpServers with command ./toolbox, args ["--prebuilt","bigquery","--stdio"], and BIGQUERY_PROJECT in the env object — then restart Claude Desktop.

Safety first
Authorization is your Cloud IAM via ADC — no API key to leak. The prebuilt toolset's tools (list_dataset_ids, get_dataset_info, list_table_ids, get_table_info, execute_sql) run queries against your grants, so scope ADC to read access (Data Viewer) on the datasets you need and nothing more. The dashboard only reads — it has no reason to mutate a table.

Step 2 — Pull the numbers

Ask Claude in plain language. It calls the MCP server's read tools to inspect your schema, then runs read-only SQL to fetch the data:

claude
Using the BigQuery MCP server, first list the datasets and the relevant table schemas, then run read-only queries for an analytics dashboard: daily active users over the last 30 days, total revenue this month vs last month, the top 10 events by count, a signup→activation→paid conversion funnel, and bytes scanned by the 5 most expensive queries this week. Summarize the figures and show me the SQL before you build anything.

Claude prints the SQL it ran, returns the figures, and you sanity-check them against the BigQuery console before going further. This is the moment to catch a wrong assumption — the wrong dataset, a timezone mismatch in the date filter, a JOIN that fans out rows — while it's cheap. Read the SQL, not just the totals.

Step 3 — Build the dashboard

Once the numbers look right, ask for the artifact:

claude
Build a single self-contained HTML dashboard from those query results. Daily active users as the hero with a 30-day trend line, then tiles for revenue this month, total events, and bytes scanned this week. A conversion-funnel section and a table of the most expensive queries 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 DAU count looks high, are we filtering out internal test accounts?" The comment is anchored to that element, not floating in a Slack thread. Claude reads the comments through the CLI, reruns the relevant BigQuery 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 test accounts from the DAU 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 BigQuery 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 BigQuery dashboard into a live canvas: every morning, re-run the queries against BigQuery 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

BigQuery dashboard with Claude — FAQ

Do I need to paste a service-account key anywhere?
No. The local MCP Toolbox authenticates over Application Default Credentials (ADC) — you run `gcloud auth application-default login` once with a read-only scope instead of pasting a key or service-account JSON. Your existing Cloud IAM roles decide what Claude can read.
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 BigQuery when someone opens the link. To refresh it, ask Claude to rerun the queries 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 BigQuery 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 BigQuery needs Google Cloud access.
Is it safe to give Claude access to my warehouse?
Connect with ADC scoped to read-only roles (BigQuery Data Viewer + Job User), and a reporting dashboard never needs more — IAM, not the tool, is what enforces read-only, so the toolbox's execute_sql can only read what your grants allow. Every call runs through the local toolbox and is audited through Cloud Audit Logs.
How is this different from Looker or a BI tool on BigQuery?
Looker and BI tools query live data against a semantic model you maintain — the right choice for governed reporting at scale. This approach is for a fast, shareable snapshot you can spin up in minutes by describing the query to Claude, then collect feedback on inline. Different jobs: one is a standing system, the other is a quick reviewable deliverable.