Maximizing the value of your Claude Code sessions
Claude Code bills tokens in two phases: prefill reads the whole request, decode generates output one token at a time, which is why output costs about 5x input. Prompt caching is automatic: shared prefixes are served at 0.1x, but switching /model, /effort, or fast mode, or running /compact, invalidates the cache and forces a full-price re-prefill. Session cost is determined by how many tokens enter the context, how many turns they stay, and how many contexts run in parallel. The guide offers concrete tactics: use @-mentions to avoid Read calls, put quiet flags for daily commands into CLAUDE.md, spill outputs over 30,000 characters to a file, use /rewind instead of /compact to trim dead ends, and offload noisy jobs to subagents (optionally pinned to haiku). Cache expiry is one hour on subscription and five minutes on API keys, extendable via ENABLE_PROMPT_CACHING_1H=1. Practical for heavy Claude Code users.