CircleCI × Metabase

How to build CircleCI dashboards in Metabase

CircleCI is a cloud CI/CD platform that runs build, test, and deploy workflows with built-in insights into pipeline performance. Metabase is where you turn that delivery activity into shared, trustworthy dashboards. This guide covers two complementary paths: a lightweight MCP + CLI route that pulls live data with the CircleCI MCP (in the CircleCI CLI) and loads a CSV into Metabase with the Metabase CLI, and a durable pipeline route that syncs CircleCI history into a database so you can build dashboards anyone can read.

Heads up: Metabase connects to databases and warehouses — it does not ship a native CircleCI connector, and a BI warehouse is the wrong home for raw logs and event streams. Sync entities and history — runs, pull requests, stories, flag changes — and leave the raw firehose in CircleCI.

How do you connect CircleCI to Metabase?

Most teams combine both routes: use MCP and CLI uploads for a fast first pass, then move recurring delivery reporting to a warehouse-backed model.

1 · MCP + CLI route (AI-assisted)

Live data in, quick analysis out

Pair the CircleCI MCP (in the CircleCI CLI) with the Metabase CLI. Use MCP for live lookups, write a scoped result to CSV, then load it into Metabase as a ready-to-query table and model.

Best for
  • Quick lookups such as "show me workflow success rate by project"
  • Loading a CircleCI export into Metabase in seconds
  • Spot-checks and one-off analyses without a warehouse
Trade-offs
  • Great for exploration, not governed delivery reporting
  • Use read-only or scoped credentials wherever the MCP server supports them
  • CSV uploads are snapshots — refresh or move to the pipeline for history
2 · Pipeline route (warehouse-backed)

Durable dashboards with history

Sync CircleCI entities and history into a database or warehouse with a connector, custom pipeline, or the API, then point Metabase at it.

Best for
  • CircleCI delivery dashboards leaders depend on
  • Joining CircleCI data with issues, deploys, incidents, or support data
  • Long-run trends for workflow success rate by project and duration p50 and p95 by workflow
Trade-offs
  • You own the refresh schedule and the table grain
  • Sync entities and rollups — not raw logs or event firehoses
  • Metric definitions must be consistent across teams and repos

What can you analyze from CircleCI data in Metabase?

Once workflow runs and the related pipelines, jobs, test metadata data are in a database, the highest-value views are:

  • Workflow success rate by project — which projects' pipelines are reliable, and which fail routinely.
  • Duration p50 and p95 by workflow — whether the feedback loop is getting slower, and for which workflows.
  • Flaky test leaderboard — the tests that waste the most reruns, from CircleCI's test metadata.
  • Credit usage by project — where CI spend concentrates, so cost conversations start from data.
  • Failed job hotspots — the specific jobs behind most workflow failures.

Which CircleCI dashboards should you build in Metabase?

For: Platform and DevX engineers

Build health

Whether the pipeline is a reliable path to production.

  • Build success rate by week (line)
  • Failed builds by job or pipeline (bar)
  • Builds per day (line)
  • Currently failing jobs (table)
For: Eng leads

Pipeline performance

Whether the path to production is getting slower.

  • Median build duration by week (line)
  • p95 duration by pipeline (bar)
  • Queue time vs. run time (stacked bar)
  • Slowest pipelines (table)
For: Test owners

Test quality

Which tests waste the most engineering time.

  • Flaky tests ranked by failure rate (table)
  • Test failures per week (line)
  • Retry volume by suite (bar)
  • New flaky tests this week (table)
For: Leadership

Delivery throughput

The shipping picture behind the DORA metrics.

  • Production deploys per week (bar)
  • Change failure rate (number + trend)
  • Lead time from commit to deploy (line)
  • Deploys by project (table)

How do you use the CircleCI MCP (in the CircleCI CLI) with the Metabase CLI?

Pair the CircleCI MCP (in the CircleCI CLI) with the Metabase CLI for fast, hands-on analysis. MCP is useful for scoped lookups and summarized exports; the Metabase CLI's upload command loads CSV data into Metabase and creates a ready-to-query table and model.

Example workflow

  • Ask the MCP server for the last 90 days of workflow runs with status, duration, and queue time.
  • Export the result as CSV, keeping stable IDs, projects, states, and timestamps.
  • Run mb upload csv to load it into Metabase as a table and model, then build questions and dashboards on top.

Be honest about the limits

  • MCP lookups are excellent for exploration, not scheduled reporting.
  • A CSV upload is a snapshot; refresh it with mb upload replace or move to the pipeline for real history.
  • Run-grain history with queued, started, and finished timestamps is required for duration and success-rate trends.
  • mb upload csv needs an uploads database configured under Admin → Settings → Uploads.

How do you set up CircleCI MCP and the Metabase CLI?

CircleCI MCP (in the CircleCI CLI)official

Transport
Local server over stdio, bundled in the CircleCI CLI
Auth
CircleCI personal API token (CIRCLECI_TOKEN)
Best for
Live scoped lookup and export

Metabase CLIofficial

Install
npm install -g @metabase/cli
Auth
mb auth login
Load data
mb upload csv --file data.csv
Requires
An uploads database (Admin → Settings → Uploads)
MCPExample MCP client config
{
  "mcpServers": {
    "circleci": {
      "command": "circleci",
      "args": ["mcp", "start"]
    }
  }
}

CircleCI folded its MCP server into the CircleCI CLI in 2026 and deprecated the standalone mcp-server-circleci package — point your client at the CLI (circleci mcp start, or circleci mcp stream for local HTTP), not at the old npm package. Self-hosted CircleCI Server works via CIRCLECI_BASE_URL.

TerminalLoad a CircleCI CSV with the Metabase CLI
# Install the Metabase CLI
npm install -g @metabase/cli

# Log in (opens your browser; requires Metabase v62+)
mb auth login --url https://your-metabase.example.com

# Load a workflow-runs export — creates a table AND a model
mb upload csv --file circleci-workflow-runs.csv --collection root

# Refresh that same table later from a new export
mb upload replace <table-id> --file circleci-workflow-runs.csv

Can you generate a CircleCI dashboard with AI?

Yes. Use the prompt below with any assistant that can run the CircleCI MCP (in the CircleCI CLI) and the Metabase CLI. It works end to end: if CircleCI tables already exist in Metabase it analyzes those; otherwise it pulls scoped, summarized data over MCP, loads it with mb upload csv, then builds the dashboard and caveats any metric that needs missing history.

Prompt for creating a CircleCI CI/CD Overview dashboard
Create a polished Metabase dashboard for CircleCI ci/cd analytics.
Work end to end: get the data into Metabase if it isn't there yet, then build.

Goal: Help engineering leaders understand build health, pipeline performance, test quality, and delivery throughput from CircleCI data.

Step 1 — Find or load the data:
- First, check what already exists in Metabase (search for circleci tables and
  models). If durable CircleCI data is already present — synced from a warehouse
  or uploaded earlier — use it and skip to Step 2.
- If nothing is there, pull a scoped, summarized export with the CircleCI MCP (in the CircleCI CLI):
  workflow runs, plus pipelines, jobs, test metadata.
  Prefer entity tables and rollups over raw logs. Write each result to a CSV,
  then load it with the Metabase CLI — run "mb upload csv --file <export>.csv" so
  each upload creates a table and a ready-to-query model. Use "mb upload replace
  <table-id> --file <export>.csv" to refresh an existing table instead of creating
  duplicates.

Step 2 — Inspect before querying:
Do not assume exact table or column names. Inspect available fields, projects,
branches, states, and timestamps, and whether history exists before creating
duration or trend cards.

Important:
- Build on whatever data is present; don't claim Metabase connects natively to
  CircleCI — it reads a database or CLI-uploaded tables.
- Never try to load raw build logs or event streams into Metabase; use runs,
  entities, state changes, and rollups.
- Only compute durations (cycle time, build duration, time to review) when the
  required timestamps exist.
- Exclude bot activity, draft work, and non-production environments from
  headline numbers, and keep the segmenting column explicit.
- A single CSV is a point-in-time snapshot: only build trend cards if there is a
  usable date column or multiple periods have been uploaded.

Dashboard title: CircleCI CI/CD Overview

Sections:
1. Executive summary: Builds last 30 days; Success rate; Median duration;
   Flaky tests flagged; Production deploys.
2. Build health: Success rate by week; failed builds by job; builds per day.
3. Performance: Median and p95 duration by week and pipeline; queue time.
4. Test quality: Flaky tests by failure rate; test failures per week; retries.
5. Throughput: Deploys per week; change failure rate; lead time where synced.

Filters: Date range, Project or Repository, Branch or Environment, Team, Status.

Output: Build the dashboard if you have permission; otherwise provide the exact
questions, SQL, model definitions, and layout. Include caveats for any metric
that cannot be calculated from the available data.

How do you sync CircleCI data into a database or warehouse?

For dashboards that need history and reliability, land CircleCI entities and change history in a database first, then connect Metabase to that database.

Connector options

  • Managed ETL — use a connector when one covers the objects you need.
  • Custom pipeline — use the CircleCI API v2 (Insights endpoints) for control over fields, grain, and refresh cadence.
  • MCP + CSV — use this for quick exploration and one-off slices.

Airbyte's marketplace CircleCI source syncs pipelines, workflows, and jobs. For metric-grade data, the Insights API already serves aggregated success rates, durations, and credit usage per workflow — a small scheduled script can land those rollups directly.

Notes

  • Land raw entity tables first, then build clean Metabase models on top.
  • Sync state-change or audit history from day one — duration metrics can't be reconstructed later without it.
  • Normalize project or job, branch, status, queued/started/finished-timestamp, and duration fields.

How should you model CircleCI data in Metabase?

Core tables

TableGrainKey columns
circleci_workflow_runsone row per workflow runid, project, workflow_name, status, branch, created_at, duration_seconds, credits_used
circleci_jobsone row per job per workflow runid, workflow_run_id, job_name, status, duration_seconds
circleci_test_resultsone row per test case per jobjob_id, suite, test_name, result, duration_seconds

Modeling advice

  • Build a clean pipeline_runs model with common columns across tools, so multi-source dashboards don't fork definitions.
  • Separate entity tables (projects, repos, flags, members) from run-grain and event-grain tables.
  • Exclude bots, drafts, and non-production environments from headline metrics; keep the flag as an explicit column.
  • Use stable IDs for project, repo, and person joins; display names change.

Which CircleCI metrics should you track in Metabase?

MetricDefinitionNotes
Build success rateSuccessful runs divided by all completed runs, per pipeline.Segment by branch; main-branch health is the headline.
Pipeline durationMedian and p95 wall-clock time from start to finish.Track queue time separately from run time.
Flaky test rateTests that both pass and fail on the same code.Rank by failure rate and time wasted, not raw count.
Deployment frequencyProduction deployments per period — a DORA throughput metric.Count deploys, not builds or merges.

What SQL powers CircleCI dashboards in Metabase?

These assume a cleaned analytical model in a warehouse (PostgreSQL dialect). Adjust table and column names to match your pipeline.

Build success rate by weekPostgreSQL

Main-branch pipeline health over time.

SELECT
  date_trunc('week', started_at) AS week,
  COUNT(*) AS builds,
  ROUND(
    100.0 * COUNT(*) FILTER (WHERE result = 'success')
    / NULLIF(COUNT(*), 0), 1
  ) AS success_rate_pct
FROM pipeline_runs
WHERE branch = 'main'
GROUP BY 1
ORDER BY 1;
Pipeline duration, median and p95PostgreSQL

Whether the path to production is getting slower.

SELECT
  pipeline_name,
  percentile_cont(0.5) WITHIN GROUP (
    ORDER BY duration_seconds
  ) / 60.0 AS median_minutes,
  percentile_cont(0.95) WITHIN GROUP (
    ORDER BY duration_seconds
  ) / 60.0 AS p95_minutes
FROM pipeline_runs
WHERE started_at >= CURRENT_DATE - INTERVAL '30 days'
  AND result = 'success'
GROUP BY pipeline_name
ORDER BY median_minutes DESC;
Flaky tests ranked by failure ratePostgreSQL

Tests that both pass and fail on the same code, trailing 14 days.

SELECT
  test_name,
  COUNT(*) AS runs,
  COUNT(*) FILTER (WHERE result = 'failed') AS failures,
  ROUND(
    100.0 * COUNT(*) FILTER (WHERE result = 'failed')
    / NULLIF(COUNT(*), 0), 1
  ) AS failure_rate_pct
FROM test_results
WHERE run_at >= CURRENT_DATE - INTERVAL '14 days'
GROUP BY test_name
HAVING COUNT(*) FILTER (WHERE result = 'failed') > 0
  AND COUNT(*) FILTER (WHERE result = 'passed') > 0
ORDER BY failure_rate_pct DESC
LIMIT 20;

What are common mistakes when analyzing CircleCI in Metabase?

Syncing raw logs or event streams into the warehouse.→ Land runs, entities, state changes, and rollups. Raw build logs and evaluation events belong in CircleCI; the warehouse is for trends and joins.
Reporting build duration as an average.→ Build times are right-skewed by cold caches and dependency changes. Use the median and p95, and trend them separately.
Mixing branches in headline success rates.→ Feature-branch failures are normal; main-branch failures are not. Keep branch as an explicit column and report main separately.
Building dashboards from live MCP lookups only.→ MCP is useful for exploration; durable dashboards need a database-backed model with history.

Related analytics

Related dashboards

Related integrations

FAQ

Does Metabase connect natively to CircleCI?
No. Metabase reads databases and warehouses. Sync CircleCI entities and history into a database first, or upload a CSV with the Metabase CLI, then build Metabase models and dashboards on top.
Should Metabase replace CircleCI's built-in reporting?
No — they answer different questions. CircleCI's own views are built for operating the tool day to day. Metabase is where you build governed, shareable reporting on top of the same data, and join it with the rest of your delivery stack — issues, deploys, incidents, and business outcomes.
Should I sync raw CircleCI build logs into my warehouse?
No. Sync run-grain records — one row per build with status, timestamps, and durations — plus per-test results if you track flakiness. Console logs are enormous, unqueryable at the SQL layer, and better served by the CI tool itself.
How do I measure flaky tests credibly?
A test is flaky when it both passes and fails against the same code. Compute it from per-test results filtered to retried runs or identical commits — see flaky test rate for the SQL patterns and the caveats about retry-based shortcuts.