Metric

What is cycle time, and how do you measure it in Metabase?

Cycle time is the elapsed time from when work startsto when it's done (completed_at − started_at). It measures active working time — how long an item takes once someone picks it up — and is the most actionable flow metric for engineering teams. Measure it in Metabase from issue-tracker data synced into a database (Linear or Jira).

TL;DR — Cycle time = started → done. It needs a reliable started_at (or status history). Lead time = created → done. Always report median (p50) and p90, not the average.

Why cycle time needs status history

started_at isn't always a stored column. The reliable way to know when work started is the status-change history: the first transition into an "in progress" state. If you only have a single resolved/completed_at timestamp, you cannot compute true cycle time — fall back to lead time and add a caveat.

  • Linear: use started_at if populated, or derive it from issue history (first move to a started workflow state).
  • Jira: derive from issue_changelog (first transition to an In Progress status); don't use resolved alone.

What data does cycle time need?

  • A reliable started_at, ideally from status-change history.
  • completed_at and a clear "done" definition.
  • For time-in-status breakdowns, the full status history (not just start/end).

SQL patterns

Median & p90 cycle time by weekPostgreSQL
SELECT
  date_trunc('week', completed_at) AS week,
  percentile_cont(0.5) WITHIN GROUP (
    ORDER BY EXTRACT(EPOCH FROM (completed_at - started_at)) / 86400.0
  ) AS median_cycle_days,
  percentile_cont(0.9) WITHIN GROUP (
    ORDER BY EXTRACT(EPOCH FROM (completed_at - started_at)) / 86400.0
  ) AS p90_cycle_days
FROM issues
WHERE state_type = 'completed'
  AND started_at IS NOT NULL
GROUP BY 1 ORDER BY 1;

Pitfalls

No started_at.→ Without it (or history), you're really measuring lead time — say so.
Averages.→ Use median and p90; durations are heavily skewed.
Cross-team leaderboards.→ Use cycle time as a within-team trend, not a ranking.
Ignoring WIP.→ High work-in-progress usually inflates cycle time — show them together.

Where this metric applies

Dashboards

Metrics

FAQ

Can I measure cycle time without status history?
Only if a trustworthy started_at exists. Otherwise use lead time and caveat the gap.
Median or average?
Median (p50) plus p90. Averages are distorted by a few long-running items.