Anthropic published the token math on Claude Code, and /clear is the cheapest habit you have
Anthropic put out a post on August 14 breaking down what actually costs money in a Claude Code session, and it hit Hacker News fast because it answers a question every heavy user has been guessing at. The framing is the good part: the same finished task can cost wildly different amounts depending on how you ran it. Not fewer tokens overall. Tokens that go toward the thing you actually asked for.
The mechanics come down to two prices. Output tokens cost more than input tokens, and cached input costs one tenth of normal input. Once you internalize that second number, most of the advice writes itself. Run /clear between tasks, because context from the last thing you did is now paying full freight on every turn of the new thing. Set your model and effort level at the very start, because changing them mid-conversation breaks the prompt cache and you re-pay for everything. Use /compact before you walk away, because the cache expires after an hour and coming back to a cold session is a full-price reload.
Two more are pure mechanical waste that most people never notice. @-mention files instead of typing paths, which skips a Read call entirely. And add quiet flags to noisy commands, or push them into a subagent, so ten thousand lines of build output do not become permanent residents of your context window. Running /context once in a fresh session tells you which tools are loaded and doing nothing, which is the same idea applied to your own configuration.
The reason this is worth reading beyond the immediate savings is that it is a vendor documenting how its own harness bills. That is rare and it is useful. Everything in that list is a statement about how context is assembled and cached under the hood, which is exactly the layer that DeepSeek made inspectable with an append-only session log this week. Two companies, opposite approaches, same admission: the context window is where the money and the failures both live, and you cannot manage what you cannot see.
Post is at claude.com/blog/maximizing-the-value-of-your-claude-code-sessions.
← Back to all articles
The mechanics come down to two prices. Output tokens cost more than input tokens, and cached input costs one tenth of normal input. Once you internalize that second number, most of the advice writes itself. Run /clear between tasks, because context from the last thing you did is now paying full freight on every turn of the new thing. Set your model and effort level at the very start, because changing them mid-conversation breaks the prompt cache and you re-pay for everything. Use /compact before you walk away, because the cache expires after an hour and coming back to a cold session is a full-price reload.
Two more are pure mechanical waste that most people never notice. @-mention files instead of typing paths, which skips a Read call entirely. And add quiet flags to noisy commands, or push them into a subagent, so ten thousand lines of build output do not become permanent residents of your context window. Running /context once in a fresh session tells you which tools are loaded and doing nothing, which is the same idea applied to your own configuration.
The reason this is worth reading beyond the immediate savings is that it is a vendor documenting how its own harness bills. That is rare and it is useful. Everything in that list is a statement about how context is assembled and cached under the hood, which is exactly the layer that DeepSeek made inspectable with an append-only session log this week. Two companies, opposite approaches, same admission: the context window is where the money and the failures both live, and you cannot manage what you cannot see.
Post is at claude.com/blog/maximizing-the-value-of-your-claude-code-sessions.
Comments