Code Mode in Claude Code Reduces Token Usage
Claude Code has introduced a Code Mode that significantly optimizes token usage and speeds up file processing.
Previously, the model read files cyclically: analysis, command execution, and repeated calls consumed significant resources. The new approach generates a short script to find the necessary data, filtering out unnecessary information before passing it to the context.
Experiments show high efficiency of this method. When searching for broken links in Markdown, only 2 steps were required instead of 13. This prevents context clutter and extends session relevance.
According to Anthropic, this approach reduces token consumption from 150,000 to 2,000.
- Mode operates in the terminal
- Requires version 2.1.323 or higher
- Enabled via CLAUDE_CODE_EXPERIMENTAL_CODE_MODE=1 variable










