Requires Node 20+, macOS (uses ps/lsof for live-session detection), and the Claude Code CLI.
Local dashboard for Claude Code sessions on this machine: live session monitoring, history, usage charts, one-click resume commands, and on-demand LLM usage analysis.
Screenshot shows sample data. Named sessions (via /rename) display their custom name; everything else falls back to the session's first prompt.
npm install
npm run dev
Open http://localhost:5173. API server runs on :3456.
- Reads transcripts from
~/.claude/projects/*/*.jsonl(incremental, append-only parsing). - Detects live sessions by matching
claudeprocesses (ps+lsofcwd) to transcript directories; falls back to "modified in last 2 minutes" if process detection is unavailable. - "Analyze my usage" runs
claude -pheadless over a digest of the last 14 days and caches the report toserver/data/last-analysis.json.
- The server binds to
127.0.0.1only (never 0.0.0.0) and enforces a Host allowlist to prevent DNS-rebinding attacks. POST /api/analyzerequires thex-claude-dashboard: 1header (the UI sends it automatically); barecurlwithout the header is rejected with 403.
npm test
All tests live in server/test/ and are run with vitest.
Spec: docs/superpowers/specs/2026-06-11-claude-dashboard-design.md
MIT — see LICENSE.
- Same-directory concurrent sessions: Two concurrent Claude sessions in the same working directory appear as a single active session —
cwd(fromlsof) is the only signal used to match a process to a transcript, so the most-recently-active transcript in that directory wins. - Subagent transcripts not counted: Transcripts stored under
projects/*/<session>/subagents/are not scanned. Token usage and session counts reflect only top-level session files. - Sessions and stats panels load once per page load: The Recent Sessions table and Charts panel fetch data once at startup and do not auto-refresh — reload the page to see new data. The Active Sessions panel auto-polls every 5 seconds.
