claude-carbon: local estimates for Claude Code sessions
claude-carbon estimates the footprint of local Claude Code sessions and keeps usage history in SQLite for reports and desktop displays.
claude-carbon is an open-source plugin that estimates the carbon footprint of Claude Code sessions from local usage records. The project's documentation describes terminal and Claude desktop displays for developers who want to inspect session activity alongside API-equivalent cost.
What does claude-carbon track?
The plugin adds a live CO2 estimate next to a session's cost and saves sessions in a local SQLite database. Its history can therefore outlast the transcript retention window described by the project.
The number is an estimate computed from usage, not a physical measurement of electricity at a data center. The displayed dollar figure is also an API equivalent: the README says subscription users should not treat it as the amount their subscription actually bills.
How do reports and displays work?
The documented commands include a text report, a PNG card and a pull-request development-footprint report. In the desktop app, the carbon panel shows a session graphic and history over a selected period.
The project says the chat and Cowork tabs and the web app are outside its coverage because their sessions do not reach the local machine for counting. That scope matters when comparing the plugin's totals with a person's overall AI use.
How do you get started?
The README describes installing the plugin through Claude Code's marketplace flow, confirming the requested installation and restarting Claude Code completely. It also lists prerequisites and troubleshooting for different operating systems.
Use one documented installation method rather than combining the plugin and separate installer, which the project says would run hooks twice. This page summarizes the workflow; Franklin has not executed the downloaded plugin or tested its calculations.
What does it cost and what are the limits?
The captured licence is MIT and grants use without a software licence charge. Access to Claude and any associated service costs are separate from this plugin.
Franklin analysis: use the estimates to compare sessions consistently under the project's methodology. Keep the method and coverage visible when sharing a report, and avoid presenting modeled CO2 or API-equivalent spending as directly measured emissions or an actual subscription invoice.
Before you try it
Frequently asked questions
Which Claude sessions are outside its coverage?
The README excludes the chat and Cowork tabs and the web app, because their sessions run remotely and do not reach the local machine for counting.
Official sourceIs the displayed dollar figure my subscription bill?
No. The project calls it an API-equivalent value based on pay-as-you-go list prices; it says Pro, Max and Ultra subscribers do not pay that displayed figure as their subscription bill.
Official sourceCan I install both the plugin and the standalone installer?
The project says to use one installation method. Combining the plugin and installer would run every hook twice.
Official source