Skip to content

Getting Started

claude-telemetry is a centralized usage tracking and analytics platform for Claude Code. It aggregates data from multiple machines into a single web dashboard.

Who Is This For?

  • Power users running Claude Code on 2+ machines who need a unified cost view
  • Team leads who want visibility into Claude Code usage across the team
  • Budget-conscious developers who want to track spending and predict rate limits

Prerequisites

RequirementVersionNotes
Node.js18+For the dashboard
Python3.11+For the sync agent
Supabase accountFree tierDatabase + auth
Cloudflare accountFree tierDashboard hosting + worker proxy

Architecture Overview

claude-telemetry has three components:

1. Supabase (Database + Auth)

Supabase provides the PostgreSQL database that stores all usage data, plus authentication via magic links with an email whitelist. The free tier is more than enough for personal use.

2. Dashboard (Cloudflare Pages)

A React web application deployed to Cloudflare Pages. It communicates with Supabase through a Cloudflare Pages Functions proxy — no API keys are ever exposed in the frontend.

Dashboard pages:

PageDescription
OverviewTotal cost, daily chart, model pie, machine cards
DailyStacked area chart, top 10 days, hour heatmap
ProjectsCost by project, pie distribution, full table
ModelsOpus/Sonnet/Haiku breakdown, mix over time, savings alert
MachinesPer-machine cards, comparison chart, status badges
DeployGenerate agent install commands with one-click copy
SessionsPaginated table with sorting and filters
InsightsRate projections, optimization tips, trend analysis
SettingsMachine management, export, alert thresholds

3. Agent (Each PC)

A lightweight Python daemon that calls ccusage to extract usage data from Claude Code's logs and syncs it to Supabase. The agent does no custom JSONL parsing — it delegates that to ccusage and focuses only on multi-PC aggregation and centralized sync. It runs as a background service (systemd on Linux, launchd on macOS, Task Scheduler on Windows) and syncs every 15 minutes by default.

Tech Stack

ComponentTechnologyHosting
AgentPython 3.11+, ccusageLocal (each PC)
DashboardReact 18, Vite, TailwindCSS, RechartsCloudflare Pages
DatabasePostgreSQLSupabase (free tier)
AuthMagic LinkSupabase Auth
API ProxyPages FunctionsCloudflare Workers

Next Steps

Ready to set up claude-telemetry? Head to the Installation Guide.

Released under the MIT License.