Claude Code Subagents Ate 48% of One Developer's Bill While Producing 0.9% of Output
A developer analyzing a month of Claude Code usage discovered that AI subagents accounted for 48% of total costs despite generating only 0.9% of output tokens. The disparity stems from how agent loops work: every tool call resends the full context window, including system prompts, tool schemas, memory files, and prior conversation history. In the developer's setup, each subagent began with roughly 51,000 tokens of fixed overhead, which was re-sent on every single model request within the loop. Long main sessions compounded the problem, with 45 sessions exceeding $100 each and accounting for 79% of total spend. The developer now recommends capping agents per run, batching smaller tasks into a single agent, trimming starting context, and handing off to a fresh session before context grows too large.
This is an AI-generated summary. ShortSingh links to the original source for the complete article.
Discussion (0)
Log in to join the discussion and vote.
Log in