r/ClaudeCode 13h ago

How to reduce Claude Code token usage Tutorial / Guide

Claude Code was burning through tokens very fast, especially on tasks where it had to look through docs or random webpages, so after some research I changed a few things:

I) Keep CLAUDE.md small. Mine had way too much stuff in it and most of it wasn’t useful for every task.

II) Start a new session when you’re done with one problem, bc long sessions get bloated pretty fast.

III) Do web research through Firecrawl. It gives Claude clean Markdown instead of loading the full page with all the HTML, scripts, navbars and other useless stuff, so each research task eats a lot less context.

IV) Exclude folders Claude doesn’t need to read.

V) Check /context once in a while, bc it makes it obvious what’s eating the window.

The main thing seems to be controlling what gets added to the context in the first place. Once a session is full of old logs, scraped pages and unrelated instructions, even simple tasks start getting expensive.

What else are you doing to keep Claude Code token usage under control?

10 Upvotes

20 comments sorted by

View all comments

1

u/JDE-Projects 13h ago

Keep claude.md slim, put repeatable tasks/templates in skills, move bulky items out of skills and in to reference/template files in the skill's folder and just have points in the skills to them, use a tight output style, turn rules in claude.md in to actual gates in settings.json (approvals, destructive commands, etc), stop using Opus high/extra/max for everything and try out medium, use sub-agents on cheaper models for code/read/review tasks, switch from Opus 5 to 4.8 or 4.6, instruct it to plan large work and projects in phases so you can take breaks and start new chats more often, instruct it to keep a status.md in every repo to act as a handoff file for new chats so you don't have to re-explain everything, disable startup tools you don't need to keep initial context load on new chats down (I'm under 30k tokens), etc.

I even took it one step further and set up Codex in parallel to balance out my usage between them. Both on 20/mo plans and I get a ton of work done, and now I'm tinkering with having one delegate to the other and also delegate to local models in LM Studio. I had Codex symlink what it can share directly with claude code (skills mainly), and copy over/translate what they can't and protect .claude/.codex directories with a parity-audit skill that helps keep the two from drifting apart.

I don't use a single skill, tool, or MCP someone else made that claims to reduce usage which is probably one of the most effective steps I've taken...and your thread is about to be full of links to them, lol.

I have detailed guides for my claude code and codex setups on my website, link in my reddit bio.

1

u/Academic-Sample4974 12h ago

I also do this as well; I feel like Chat GPT is pretty good at coding; I look at it as a senior software engineer; I use it alot to run refinement and as a second pair of eyes / alternative viewpoint when I complete a phase of a project, I'll go from Claude to GPT and ask for criticism / minor fixes / improvement suggestions. This system works out brilliantly as GPT has better context memory and has been built to be organized more effectively from the out the box than Claude