← All Blog articles
SaaSClaude Code使用量

Claude Code /usage: Breakdown, Session Cost and Zero Results

12 min read

Go deeper on this topic

SaaS integrations

Give AI the context to continue the work: source conversations, open tasks, and unresolved details, from adoption decisions to integration code.

Article 6 of 11 in this series.

View topic page

Use the topic hub as a map, then continue to the next article in the series. New here? Start at the home hub →

Read Claude Code /usage by separating current-session cost from subscription usage. A recommendation's percentage describes usage it applies to, rather than promised savings. In our isolated experiment, the zero returned by claude -p "/usage" described a fresh, unauthenticated session.

Checked: 2026-10-27. Tested version: Claude Code 2.1.308 on macOS with Node.js 26.12.1. We read the official documentation that day and the changelog through its 2.1.311 heading. We did not measure the signed-in subscription interface.

Key points: Match the device and reporting window before choosing one workflow to investigate. Zero cost in a new session does not establish account-wide usage or remaining allowance.

Which part of /usage answers my question?

The documentation distinguishes Session token/cost estimates from plan usage for Pro, Max, Team and Enterprise subscribers. Session cost is not the subscriber's bill. Attribution is estimated from this device's last 24 hours or seven days; other devices and claude.ai are outside that local history. Official usage guide

Question Where to look Conditions to hand over
Session consumption Session in /usage Session, CLI version and timestamp
Feature attribution Signed-in usage breakdown Device, day/week window and displayed categories
Current context /context Current context state

The command reference lists /cost and /stats as aliases of /usage. /context concerns the current context, a different question from historical usage. Official command reference

Does a recommendation's percentage equal savings?

Attribution covers skills, subagents, plugins and MCP servers. Recommendation shares describe affected usage, and may overlap beyond 100%. They are not saving estimates. Investigate the relevant work before changing it. Breakdown definition

For example, an MCP category is a reason to examine which task consumed its results, before removing a connection by name. When reviewing instructions, distinguish required procedures from explanations unrelated to the current task. These are proposed investigation steps, not savings measured in this experiment.

The documented f shortcut requires 2.1.305 or later and acts on some recommendations; a row labeled run needs manual action. We did not press f. Fix-shortcut conditions

The changelog records alias consolidation in 2.1.118, category attribution in 2.1.149, an MCP over-attribution fix in 2.1.222, and actionable fixes in 2.1.305. Include the version when comparing older explanations. Official changelog

What did zero from claude -p "/usage" measure?

We ran /usage, /cost and /stats twice each on Claude Code 2.1.308: six independent runs. Each had a fresh temporary HOME and CLAUDE_CONFIG_DIR, without existing credentials or history. Tools and MCP were disabled. This was separate from measuring the interactive subscription display.

Field /usage /cost /stats
Runs 2 2 2
Exit code Both 0 Both 0 Both 0
num_turns Both 0 Both 0 Both 0
duration_api_ms Both 0 Both 0 Both 0
Reported tokens All 0 All 0 All 0

All six returned the same text. Their JSON local_command fields were usage, cost and stats, respectively.

Total cost:            $0.0000
Total duration (API):  0s
Total duration (wall): 0s
Total code changes:    0 lines added, 0 lines removed
Usage:                 0 input, 0 output, 0 cache read, 0 cache write

The JSON modelUsage object was also empty. These are local-command statistics for fresh unauthenticated sessions. Subscription usage remains unknown. Do not use this result to establish remaining allowance or that real work is free. Recorded output JSON

How can I reproduce this check?

Save the probe script and run it with Claude Code on PATH. It uses Node.js standard libraries, without additional packages. Starting it without --run makes no CLI call.

node usage-command-probe.mjs --run > observations.json
node usage-command-probe.mjs --validate observations.json

For each slash command, it supplies the arguments below. The input settings file contains {} followed by a newline. The JSON records HOME, config directory, working directory, timestamps and the complete argument array.

claude -p /usage --safe-mode --settings <fresh>/settings.json
  --setting-sources "" --strict-mcp-config --mcp-config '{"mcpServers":{}}'
  --tools "" --max-turns 1 --max-budget-usd 0.10
  --output-format json --no-session-persistence

This is an argument illustration, not a multiline shell command to paste. Use the script. All six settings files had this SHA-256:

ca3d163bab055381827226140568f3bef7eaac187cebd76878e0b63e9e442356

Validation checks model turns, API duration, settings hashes and that unknown subscription usage stays null. Changing a record to claim a model turn or a measured subscription fails validation. This checks the observation contract, not Claude Code's overall safety.

What should I hand AI after reviewing usage?

This worksheet is our proposed handoff format. Write “unknown” for missing fields instead of filling them with zero. Before changing every large category, choose one workflow, a proposed change, and a way to check its result.

Timestamp and CLI version:
Device and reporting window:
Session statistics or signed-in plan display:
Displayed attribution and recommendations:
One workflow to investigate, and why:
Instructions, connections and tests to preserve:
What to check after the change:
Unknown or untested:

For configuration ownership, see MCP scopes. Before trimming instructions, check CLAUDE.md and AGENTS.md loading. For moving conversations, use the context handoff guide.

What remains unverified?

We did not test signed-in attribution, attribution accuracy, changes made by f, savings on real work, quota resets, other versions or providers. We did not read account history. Keep the documented interface separate from the isolated local-command observations.

FAQ

Q. How should I read Claude Code /usage?
Separate current-session statistics from plan usage. Record the device and 24-hour or seven-day window when reading attribution. Recommendation percentages are not saving rates. We did not measure the signed-in display.
Q. Is Total cost in /usage my subscription bill?
The documentation describes Session cost as a token-based estimate, not a Pro or Max subscription bill. Zero in our fresh unauthenticated sessions also does not establish account-wide usage or remaining allowance.
Q. Do /cost and /stats measure different usage?
The official reference lists them as aliases of /usage. In isolated print mode on 2.1.308, two runs of each command returned identical zero-session statistics. We did not test tabs in the signed-in interactive display.
Q. Does the usage breakdown include other devices?
The documented breakdown is estimated from local history on this device and excludes other devices and claude.ai. Record the device and window instead of treating attribution as the same scope as account-wide allowance.