What Counts as Token Usage in Claude Code
Token usage in Claude Code is the total amount of text the model processes on each turn, measured in tokens - small chunks of text roughly the size of a few characters or a short word. Every turn has two halves: input tokens (everything Claude Code reads before it responds) and output tokens (everything it writes back). Both count against your usage, and output tokens are the more expensive half.
The part most people miss is that Claude Code is stateless between turns. It does not remember your last message on its own - the full conversation so far is re-sent as input on every single turn so the model can see the whole thread. That means a session that has run for twenty messages is sending twenty messages of history as input on message twenty-one, before you have even added your new request. This is why long sessions feel like they get slower and burn usage faster: the input is growing every turn.
The four things that make up your Claude Code token usage on a turn
| Component | Counts as | What drives it up |
|---|---|---|
| Your prompt | Input | Long, rambling requests instead of tight ones |
| Loaded context | Input | A bloated CLAUDE.md, and files Claude reads in full |
| Conversation history | Input | Long sessions - the whole thread is re-sent every turn |
| Claude's response | Output | It rewriting whole files instead of a targeted change |
The Biggest Silent Drain: Reading Whole Files It Did Not Need
The single largest source of wasted token usage is Claude Code reading large files in full when it only needed a small part of them. When you ask a vague question in a big project, Claude Code opens files to figure out where the relevant code lives - and a single large file can be thousands of tokens of input, most of which was irrelevant to the change you wanted.
The fix is to point it at the exact target. Instead of "fix the login bug," say "in src/lib/auth.ts, the token refresh on line 40 is not clearing the old session - fix that." Now Claude Code reads one file, or one section, instead of hunting through five. In the Claude Code desktop app you can drag the specific file into the conversation so it never has to search. Every file it does not have to open is input you did not spend.
Why Long Sessions Cost More Per Message
Because the whole conversation is re-sent as input on every turn, a marathon session gets more expensive the longer it runs - even if your individual messages stay short. The first message in a session might send a few hundred tokens of input. The fiftieth message sends the accumulated history of the first forty-nine turns before your new request is even read. You are paying to re-transmit the entire backstory over and over.
The fix is conversation hygiene: start a fresh session when a task is done. End a focused work block with a one-line summary - "we added the invoice PDF export and fixed the date bug; next is the email step" - then open a new session and paste that summary as the first message. You carry forward the decisions without dragging the entire transcript, which resets your input cost back to near zero.
Plan Mode Saves Output Tokens on Big Tasks
Output tokens are the expensive half of usage, and the most wasteful output is a large build that went in the wrong direction. When you ask Claude Code to implement a big feature in one shot, it may write hundreds of lines across several files before you get to see whether the approach was right. If it was wrong, you have paid for all that output and now have to pay again for the rewrite.
Plan mode fixes this. You ask Claude Code to produce a plan first - the files it will touch, the approach, the order of steps - and you approve or correct it before it writes a single line of implementation. The plan is cheap output; the wrong implementation is expensive output. Catching a bad approach at the plan stage is the highest-leverage way to cut output token usage on anything non-trivial.
- Use plan mode for anything that touches more than one or two files, so you approve the shape before the spend.
- Ask for a targeted edit, not a full-file rewrite, when the change is small - "change only the refresh function" produces far less output than "rewrite this file."
- Break large asks into a sequence of small, verified steps rather than one giant request that produces a wall of output you then have to unwind.
Keep Your CLAUDE.md Lean
Your CLAUDE.md file loads as input at the start of every session, so its length is a fixed tax on every conversation. A tight, 300-word CLAUDE.md that states your stack, your conventions, and your no-go zones is a good investment. A 5,000-word CLAUDE.md that tries to document everything is spending token budget on rules the model rarely needs, on every single turn, forever.
Aim for the shortest CLAUDE.md that reliably stops the mistakes you actually see. If Claude Code keeps using the wrong import, add a line about your stack. If it keeps touching a folder it should not, add a no-go line. Do not pre-load rules for problems you do not have. Lean context is cheaper and, again, more accurate - the model is not diluted by rules that do not apply to the task in front of it.
How to Tell What Is Using Your Usage
If you feel like you are hitting limits faster than the work justifies, the cause is almost always one of the drains above rather than the volume of real work. Run through this checklist before assuming you need a bigger plan. Most usage problems are a context problem in disguise.
Symptom, likely token drain, and the fix
| Symptom | Likely cause | Fix |
|---|---|---|
| Usage climbs even on small asks | A long-running session re-sending its history | Start a fresh session with a one-line summary |
| Every session feels heavy from the start | A bloated CLAUDE.md loading as input each time | Trim CLAUDE.md to the rules that stop real mistakes |
| Claude reads lots of files per request | Vague prompts making it search for the target | Name the exact file and function in your message |
| Big builds burn output then need redoing | Skipping plan mode on multi-file work | Approve a plan before it writes the implementation |
| Large responses for tiny changes | Asking for full-file rewrites | Ask for a targeted edit to the specific block |
If you have tightened all of that and still consistently run out, that is the signal that your workload genuinely needs more headroom - and that is a plan question, not a usage-discipline question. The [which Claude plan for Claude Code](/blog/which-claude-plan-for-claude-code) post breaks down Pro versus Max by real usage, and the [Claude Code usage limits guide](/blog/claude-code-usage-limits-what-to-do) covers what to do the moment you hit a cap mid-build.
Short, practical drops on skills, MCP, agents, prompts, and more. No spam, unsubscribe anytime.
Frequently asked questions
What uses the most token usage in Claude Code?
The largest single drain is Claude Code reading whole files it did not need because the request was vague. The second is conversation history: because the full thread is re-sent on every turn, a long session sends more and more input each message. Output tokens are the most expensive per token, so a large build that went the wrong way and had to be redone is also costly.
Does a long Claude Code session use more tokens?
Yes. Claude Code is stateless between turns, so the entire conversation so far is re-sent as input on every turn. On the fiftieth message it is sending the accumulated history of the first forty-nine turns before it even reads your new request. Starting a fresh session with a short summary resets that input cost back to near zero.
How do I reduce token usage in Claude Code?
Point Claude at specific files instead of letting it search, keep your CLAUDE.md short (a few hundred words, not thousands), start a fresh session when a task is done rather than running a marathon thread, and use plan mode on multi-file work so you approve the approach before it spends output tokens building it.
Do input and output both count toward Claude Code usage?
Yes. Input is everything Claude Code reads on a turn - your prompt, your CLAUDE.md, the files it opens, and the conversation history. Output is everything it writes back. Both count, and output is the more expensive half per token, which is why avoiding wrong-direction builds with plan mode matters so much.
Does a big CLAUDE.md file increase token usage?
Yes. Your CLAUDE.md loads as input at the start of every session, so its length is a fixed cost applied to every conversation. A lean CLAUDE.md that states your stack, conventions, and no-go zones in a few hundred words is efficient. A multi-thousand-word file spends token budget on rules the model rarely needs, every turn.
Last reviewed by David Iya on September 8, 2026


