Skip to main content

Claude Code session cost analytics: your tokens are burning

Project description

Burnie

Some agents just want to watch your tokens burn.


burnie is a local cost analytics tool for Claude Code. It reads the session transcripts Claude Code stores on disk and tells you not just how much your sessions cost, but whether a given session was abnormally expensive, and what you can say about why.

burnie report

Features

  • Report: a visual HTML breakdown of token costs across all your Claude Code sessions, covering total spend, daily average, cache savings, and cost by model and by project.
  • Inspect: drill into any session to see what drove the cost, including context growth over time, tool call patterns, agent spawns, repeated operations, and how it compares to similar sessions.
  • Analyze: the /burnie skill runs a condensed report through Claude for a written, reasoned take on where your cost is coming from and what (if anything) is actually worth changing.

Install

# run without installing
uvx burnie

# or install as a persistent command
uv tool install burnie

No uv? pip install burnie works too.

Then get the /burnie skill into Claude Code:

burnie --install-skill

Usage

# Generate HTML report
burnie

# Highlight a specific session in the report
burnie --session <session-id>

# Markdown report instead of HTML
burnie --markdown

# Condensed, LLM-readable report printed to stdout (what the `/burnie` skill uses)
burnie --raw --session <session-id>

The report is written to burnie-report.html in the current directory and opened in your browser. --markdown writes burnie-report.md instead. --raw prints straight to stdout with no file.

Cost & privacy

  • The dollar figures are API-equivalent costs, from Anthropic's published API rates. They are not necessarily what a Pro or Max plan bills you. Read them as "what this usage would cost at API prices," good for comparing sessions, not an invoice.
  • The report is generated entirely on your machine. No API key, no account access, no data leaves your computer. burnie only reads the JSONL files Claude Code already wrote to disk.
  • The optional /burnie skill passes the condensed report to your own running Claude Code session for analysis. That stays local to your session, not a call to any burnie backend (there isn't one).

How it works

Claude Code writes every session to a JSONL file at:

~/.claude/projects/<encoded-project-path>/<session-id>.jsonl

Each assistant turn includes token usage. burnie reads those files, applies current model pricing (bundled with the package and updated periodically as Anthropic changes its rates), and surfaces the data.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

burnie-0.1.2.tar.gz (1.1 MB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

burnie-0.1.2-py3-none-any.whl (133.3 kB view details)

Uploaded Python 3

File details

Details for the file burnie-0.1.2.tar.gz.

File metadata

  • Download URL: burnie-0.1.2.tar.gz
  • Upload date:
  • Size: 1.1 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: uv/0.11.29 {"installer":{"name":"uv","version":"0.11.29","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for burnie-0.1.2.tar.gz
Algorithm Hash digest
SHA256 0af608521794c57e77cc4525a7339d902fe745767dc16377525b1a54d85e1bc5
MD5 e4683ad10a2f46da258351b0642a23fc
BLAKE2b-256 d5fceefd73421056e33d3f02749ba8e0c93616797d4c21be6ff89808ca793576

See more details on using hashes here.

File details

Details for the file burnie-0.1.2-py3-none-any.whl.

File metadata

  • Download URL: burnie-0.1.2-py3-none-any.whl
  • Upload date:
  • Size: 133.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: uv/0.11.29 {"installer":{"name":"uv","version":"0.11.29","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for burnie-0.1.2-py3-none-any.whl
Algorithm Hash digest
SHA256 3cc5eb486bc55539c0c75844e28d1f97d1134b2189d94cddd55a7ca4971b01c8
MD5 0f05c0be1c9a8eb07e57db9a3f030f04
BLAKE2b-256 67f9bc64f0ddcb7739ce826f6a7dc44d8d761821efc6933e4a92ca874dd3b826

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page