Managing Your Budget
Claude Code is billed based on input and output tokens. Large codebases can quickly consume tokens if not managed correctly.
Context Bloat
Every file Claude reads adds to the context window. Asking to "refactor the whole project" may attempt to read every file, leading to high costs.
Efficient Reading
Encourage targeted reading:
- Use grep to find specific lines first
- Read only relevant files
- Use
.claudeignorefor large artifacts
Cost Tip
Add dist/, node_modules/, and large data files to .claudeignore. Claude shouldn't spend money reading files it can't meaningfully edit.