Open Source Grafana Dashboard Tracks Claude Code Costs and Usage via OpenTelemetry

A Grafana dashboard for tracking Claude Code costs and usage is now available open source. Built by an SRE who noticed that Claude Code's OpenTelemetry (OTel) metrics capability landed quietly, the dashboard pulls OTel metrics into any Prometheus-compatible backend — including Prometheus, VictoriaMetrics, Mimir, or Thanos.
What It Shows
- Cost broken down by model, project, and user
- Token usage over time
- Cache hit ratio — the single biggest lever on bill predictability
- Active time, lines of code touched, commits, and PRs Claude opened
- Edit-decision breakdowns (accept vs. reject)
Custom Labels for Grouping
Use OTEL_RESOURCE_ATTRIBUTES to add custom labels and group data by team or project. This makes it easy to attribute costs to specific teams or initiatives.
How to Get It
- Article with full setup guide: rockdarko.dev
- Direct download from Grafana Labs: Dashboard ID 25255
- Repository (MIT licensed): github.com/rockdarko/claude-code-metrics-prometheus
Inspired by the existing Azure Application Insights dashboard for Claude Code, this implementation targets teams running open-source observability stacks. The dashboard is MIT licensed and ready to import into your Grafana instance.
📖 Read the full source: r/ClaudeAI
👀 See Also

Freestyle Launches Sandboxes for AI Coding Agents with Live Forking
Freestyle provides cloud sandboxes for AI coding agents that start in ~500ms and feature live forking with <400ms pause, allowing full VM clones including memory state. They run full Debian with hardware virtualization on bare metal infrastructure.

Security scanning skill for AI coding agents automatically checks deployments
A developer created a skill file that enables AI coding agents to automatically scan their own deployments for security issues like exposed secrets, open ports, missing security headers, and leaked source code. The scan runs after every deploy and takes about 30 seconds.

Agent Swarm: Multi-Agent Orchestration Framework for AI Coding Assistants
Agent Swarm is an open-source framework that enables teams of AI coding agents to coordinate autonomously. A lead agent receives tasks from Slack, GitHub, or email, breaks them down, and delegates to Docker-isolated worker agents.

Claude AI Built a UFO Data Visualizer with Government Data in Hours
A Reddit user used Claude AI to build a full-stack UFO sighting visualizer from newly released U.S. Dept. of War data, hosted on Cloudflare, in just a few hours.