Skip to main content

Live terminal dashboard for tracking Claude Code usage and costs

Project description

claude-cost

Live terminal dashboard for tracking Claude Code token usage and costs.

Install as a Claude Code skill

/plugin marketplace add mohsinahad/claudemeter
/plugin install claude-cost@claude-cost

Then use:

/claude-cost             # launch live dashboard in a new tab
/claude-cost summary     # print today/month costs inline
/claude-cost reset       # reset config to defaults

Install as a standalone CLI

pipx install claude-cost        # recommended
# or
pip install claude-cost

Note: If pip warns that the script is installed in ~/.local/bin which is not on PATH, add this to your ~/.zshrc or ~/.bashrc:

export PATH="$HOME/.local/bin:$PATH"

Then run:

claude-cost           # live dashboard
claude-cost summary   # quick inline summary
claude-cost reset     # reset config

Budget alerts

Set spending limits in ~/.claude/dashboard_config.json:

{
  "daily_budget": 5.00,
  "monthly_budget": 50.00
}

To get automatic warnings after each Claude session, add a hook to ~/.claude/settings.json:

{
  "hooks": {
    "Stop": [
      {
        "hooks": [
          {
            "type": "command",
            "command": "claude-cost check-budget"
          }
        ]
      }
    ]
  }
}

Claude will print a warning in your session whenever you hit 80% or 100% of your budget.

Usage

claude-cost --help     # show help
claude-cost --version  # show version
claude-cost            # launch the dashboard
claude-cost summary    # print costs inline (no TUI)
claude-cost check-budget  # check limits (exits 2 if over 80%)
claude-cost reset      # reset config to defaults

Keys inside the dashboard:

Key Action
q Quit
r Refresh
1 Last 24 hours
7 Last 7 days
3 Last 30 days

What it shows

  • Token usage (input / output / cached) per model
  • Cost breakdown by session and cumulative
  • Human cost estimate (time saved vs. manual coding)
  • Live-updating as you work

No API key or extra config needed — reads directly from ~/.claude/.

Requirements

  • Python 3.11+
  • Claude Code installed and used at least once (data lives in ~/.claude/)

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

claude_cost-0.1.1.tar.gz (15.2 kB view details)

Uploaded Source

Built Distribution

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

claude_cost-0.1.1-py3-none-any.whl (15.3 kB view details)

Uploaded Python 3

File details

Details for the file claude_cost-0.1.1.tar.gz.

File metadata

  • Download URL: claude_cost-0.1.1.tar.gz
  • Upload date:
  • Size: 15.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for claude_cost-0.1.1.tar.gz
Algorithm Hash digest
SHA256 fe94f9f5896bfc26e475d8c8180f122b5266212b8a9906a7949704b6cd1302b6
MD5 dacc00c8089bf63e6ff94b9d09680a1d
BLAKE2b-256 252839d53e17e54291a29376bca9fd491b6cea5d856ac556f3864ba1b4a863f4

See more details on using hashes here.

Provenance

The following attestation bundles were made for claude_cost-0.1.1.tar.gz:

Publisher: publish.yml on mohsinahad/claude-cost

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file claude_cost-0.1.1-py3-none-any.whl.

File metadata

  • Download URL: claude_cost-0.1.1-py3-none-any.whl
  • Upload date:
  • Size: 15.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for claude_cost-0.1.1-py3-none-any.whl
Algorithm Hash digest
SHA256 2cc6d2d86b4f6907db2d2cfdf14a50f514549a6fcb658f77e84656f782c97b05
MD5 f2c828b4f900a353bd090c030ac3c338
BLAKE2b-256 9a6188200a0a2ea57681799ea9b4573d2164a84e630c632efb02288266343b33

See more details on using hashes here.

Provenance

The following attestation bundles were made for claude_cost-0.1.1-py3-none-any.whl:

Publisher: publish.yml on mohsinahad/claude-cost

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

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