Agent token usage: where the tokens go and how to spend fewer
ExplainerBy Lucas Matías García TorresUpdated Data checked 6 min read
Reviewed on . How we work.

Short answer
Agents use far more tokens than chats because every step of their loop resends the instructions, tool definitions and all earlier results; Anthropic reported about four times more tokens for agents and fifteen times for multi-agent systems. In our ten-step example, one run sends 130,750 input tokens and costs from $0.014 to $0.376 on four current models, and caching cuts that by 69% to 73%. Tool search, shorter tool results and step limits cut it further.
Prices and limits change often: check the vendor's page before you pay. How we make money.
An agent is a model working in a loop: it reads the task, calls a tool, reads the result and decides the next step until the job is done. Every turn of that loop is a new request that carries everything before it, which is why agent token usage climbs so fast. Anthropic reported in 2025 that, in its data, agents typically use about four times more tokens than chat interactions, and multi-agent systems about fifteen times more. This guide explains where those tokens go, works through the cost of one agent run on current prices, and lists the techniques the providers themselves document to cut the bill.
Why an agent uses so many tokens
A chat answers once per question. An agent may need ten or twenty model calls to finish one task, and each call is billed in full. Four things fill those calls:
- Instructions and tool definitions. The system prompt and the description of every tool the agent may use travel with every request. Tool definitions count as input tokens, as our guide to function calling explains.
- Tool results. A file the agent opened, a web page it fetched or rows it read from a database become part of the conversation and are sent again on every later step.
- The model's own calls. Each tool call the model writes is output on the step where it is written and input on every step after.
- Hidden reasoning. OpenAI says reasoning tokens are not visible through the API but still take space in the context window and are billed as output tokens, and that a model may generate from a few hundred to tens of thousands of them for one response.
The result is that the cost of an agent grows faster than the number of steps: step ten resends everything steps one to nine produced.
A worked example: one agent run, ten steps
Take an agent with a fixed part of 5,000 tokens (a 1,000-token system prompt and 4,000 tokens of tool definitions) and a 200-token task. On each step it writes a 250-token tool call and gets back a 1,500-token tool result; on the tenth step it writes a 500-token answer. We leave hidden reasoning out for now.
Table: input tokens per step in the example agent run (our calculation)
| Step | Input tokens sent |
|---|---|
| 1 | 5,200 |
| 2 | 6,950 |
| 5 | 12,200 |
| 10 | 20,950 |
| Total over 10 steps | 130,750 |
One run uses 130,750 input tokens and 2,750 output tokens, about 18 times the 7,300 tokens of the four-turn conversation in our chatbot cost example. The fixed 5,000 tokens alone, repeated ten times, are 38% of the input.
Table: cost of the example run on prices read October 28, 2026 (our calculation)
| Model | Per run, no cache | Per run, with caching | 1,000 runs a month, no cache / with caching |
|---|---|---|---|
| GPT-6 Luna | $0.014 | $0.005 | $14 / $5 |
| Claude Haiku 5.5 | $0.019 | $0.006 | $19 / $6 |
| GPT-6.1 Terra | $0.145 | $0.039 | $145 / $39 |
| Claude Sonnet 5.5 | $0.376 | $0.103 | $376 / $103 |
The Claude rows include the roughly 30% extra tokens that Anthropic says its newer tokenizer produces for the same text. The caching column assumes the fixed part is already cached and that each step writes only its new content to the cache, at 1.25 times the input price, as OpenAI and Anthropic charge for writes.
Two variations show how quickly this moves. Doubling the run to 20 steps multiplies its cost by about 3.2, not 2, because every extra step resends a longer history. And if the model also spends 1,000 hidden reasoning tokens per step, the cost of the ten-step run rises by about 35% on all four models.
Tool definitions: the cost before any work starts
Connecting an agent to many tools is convenient, and expensive. In a November 2025 engineering post, Anthropic described a setup with five MCP servers whose 58 tools took about 55,000 tokens before the conversation even started, and said it had seen tool definitions take 134,000 tokens before optimization.
Anthropic's own answers show the scale of the savings available:
- Search for tools instead of loading them all. With its Tool Search Tool, only the search tool is loaded up front and three to five relevant tools are found when needed. In Anthropic's example, context use fell from about 77,000 tokens to about 8,700, an 85% reduction.
- Let the agent write code against tools. In another post on code execution with MCP, Anthropic gave an example where the token use of a task fell from 150,000 tokens to 2,000, a 98.7% saving, because intermediate results stayed in the code execution environment instead of passing through the model's context window.
Your own savings will depend on your tools and tasks; these are Anthropic's examples, not guarantees.
Six ways to spend fewer tokens
- Cache the fixed part. The system prompt and tool definitions repeat exactly on every step, which makes them ideal for prompt caching. In the example above, caching cuts the cost of a run by 69% to 73%.
- Offer fewer tools at a time. Load the tools a task needs, or let the agent search for them, instead of attaching every tool to every request.
- Keep tool results short. Return the fields the agent needs, not a whole document or database table. Anthropic's context editing can also clear old tool results automatically once the context passes a threshold you set; since clearing invalidates the cached prefix, Anthropic suggests clearing enough tokens at once to make the lost cache worthwhile.
- Cap steps and output. Set a maximum number of steps for the loop, and use the output limit: OpenAI notes that
max_output_tokenslimits the total generated, reasoning tokens included. - Match the model to the step. Routine steps rarely need the most capable model. The price gap in the table above, more than 25 times between GPT-6 Luna and Claude Sonnet 5.5 for the same run, is the reason to route.
- Measure every run. OpenAI reports reasoning tokens in the usage of each response, and Anthropic reports cache reads and writes. Log them per task and per step to see which part of the loop is expensive.
Are more tokens always a bad sign?
Not necessarily. In Anthropic's analysis of its research agent, three factors explained 95% of the variance in performance on the BrowseComp evaluation, and token usage by itself explained 80%, with the number of tool calls and the choice of model as the other two. Spending more tokens is often how an agent gets better results. Anthropic's conclusion was economic: multi-agent systems need tasks whose value is high enough to pay for the extra performance.
The practical question is therefore not how to use the fewest tokens, but whether each run is worth what it costs. Price a sample of real runs before you scale, as in our guide to agents for business, and check that the expensive steps are the ones doing useful work.
How we checked
We read Anthropic's engineering posts on its multi-agent research system (June 13, 2025), on advanced tool use (November 24, 2025) and on code execution with MCP (November 4, 2025), Anthropic's context editing documentation and OpenAI's reasoning models guide on October 28, 2026. Prices come from the same pricing pages used in our cost calculator, read the same day. The agent run is our own illustrative example, not a measurement of a real agent.
What we checked
- Anthropic (How we built our multi-agent research system, June 13, 2025): in its data, agents typically use about 4x more tokens than chat interactions and multi-agent systems about 15x more; three factors explained 95% of the performance variance in the BrowseComp evaluation, token usage alone 80%, with the number of tool calls and model choice as the other two; multi-agent systems need tasks valuable enough to pay for the increased performance. (Anthropic, )
- Anthropic (Introducing advanced tool use, November 24, 2025): five MCP servers with 58 tools consumed about 55K tokens before the conversation started; tool definitions consumed 134K tokens before optimization at Anthropic; with the Tool Search Tool, context consumption fell from about 77K to about 8.7K tokens, an 85% reduction. (Anthropic, )
- Anthropic (Code execution with MCP, November 4, 2025): passing intermediate results through the context window slows agents and increases costs; with code execution, intermediate results stay in the execution environment; an example task fell from 150,000 to 2,000 tokens, a 98.7% saving. (Anthropic, )
- Anthropic context editing: the tool result clearing strategy clears the oldest tool results when context passes a configured threshold and replaces them with placeholder text; tool result clearing invalidates cached prompt prefixes, so clear_at_least sets a minimum number of tokens to clear each time. (Anthropic, )
- OpenAI reasoning models: reasoning tokens are not visible via the API but occupy space in the context window and are billed as output tokens; models may generate from a few hundred to tens of thousands of reasoning tokens; max_output_tokens limits the total generated tokens including reasoning; reasoning token counts appear in the usage object under output_tokens_details; GPT-5.6 models by default render available reasoning from earlier turns. (OpenAI, )
- OpenAI Standard prices per million tokens: GPT-6 Luna $0.10 input, $0.01 cached input, $0.50 output; GPT-6.1 Terra $1, $0.05 and $5. (OpenAI, )
- Anthropic prices per million tokens: Claude Haiku 5.5 $0.10 input, $0.01 cache hits, $0.50 output; Claude Sonnet 5.5 $2, $0.10 and $10; its tokenizer for Claude 4.7 and later produces approximately 30% more tokens for the same text. (Anthropic, )
- OpenAI charges cache writes at 1.25 times the uncached input rate for the default 30-minute lifetime on GPT-5.6 and later. (OpenAI, )
- Anthropic charges 5-minute cache writes at 1.25 times the base input price. (Anthropic, )
What may change
- Prices, tool features and context management options change often. This page is reviewed quarterly.
Frequently asked questions
Why do agents use so many more tokens than a chat?
Because an agent works in a loop and every step is a new request that resends the instructions, the tool definitions and everything earlier steps produced. A task that needs ten model calls pays for the growing history ten times. Anthropic reported that agents typically use about four times more tokens than chat interactions in its data.
How much does one agent run cost?
It depends on the steps, the tools and the model. In our example of ten steps with 5,000 tokens of instructions and tools and 1,500-token tool results, one run costs from about $0.014 on GPT-6 Luna to about $0.376 on Claude Sonnet 5.5 at prices read on October 28, 2026, before caching.
Do tool definitions count as tokens?
Yes. Tool definitions are sent as input on every request that offers them. Anthropic described a setup in which 58 tools from five MCP servers took about 55,000 tokens before the conversation started, and showed that searching for tools on demand cut context use by 85% in its example.
What is the quickest way to cut an agent's token bill?
Cache the fixed part. The system prompt and tool definitions repeat exactly on every step, so prompt caching makes most of the input cheaper; in our example it cuts the cost of a run by 69% to 73%. After that, load fewer tools per request, return shorter tool results and cap the number of steps.
Sources
- How we built our multi-agent research system (Anthropic, June 13, 2025): token use of agents and multi-agent systems, Anthropic. Accessed October 28, 2026.
- Introducing advanced tool use for Claude (Anthropic, November 24, 2025): tool definition tokens and the Tool Search Tool, Anthropic. Accessed October 28, 2026.
- Code execution with MCP for efficient agents (Anthropic, November 4, 2025), Anthropic. Accessed October 28, 2026.
- Context editing (Claude Platform Docs): tool result clearing and prompt caching, Anthropic. Accessed October 28, 2026.
- Reasoning models (OpenAI API guide): reasoning tokens, billing, context and max_output_tokens, OpenAI. Accessed October 28, 2026.
- OpenAI API pricing: Standard table for GPT-6 Luna, GPT-6.1 Terra and GPT-6.1 Sol, OpenAI. Accessed October 28, 2026.
- Claude API pricing: Haiku 5.5 and Sonnet 5.5, cache multipliers and the newer tokenizer, Anthropic. Accessed October 28, 2026.
- Prompt caching (OpenAI API guide): on by default, 1,024-token minimum, write and read rates for GPT-5.6 and later, OpenAI. Accessed October 28, 2026.
- Prompt caching (Claude API): automatic caching, minimum lengths by model, lifetime and pricing multipliers, Anthropic. Accessed October 28, 2026.
Spotted an error or an outdated price? Tell us and we will fix it.
Change history
- : First published. Checked against Anthropic's engineering posts and context editing documentation, OpenAI's reasoning guide and the providers' pricing pages on October 28, 2026.
Next review: .
Part of our Agents & Automation guide.
Keep reading
- What is an agent?
What an agent is, how it differs from a chatbot or a workflow, how the plan-act-observe loop works, real examples, when you do not need one and the risks.
- Agents for business: use cases, costs and risks
Which business tasks suit an agent, whether you need one, three ways to get one, what model calls cost in a worked example, the main risks and EU rules.
- Function calling: how a language model uses your tools
Function calling explained: how a model asks your code to run a tool, the settings OpenAI, Anthropic and Google offer, what it costs and how many tools to give.
- What is MCP (Model Context Protocol)?
What the Model Context Protocol is, how hosts, clients and servers work, what tools, resources and prompts are, and the security rules the MCP spec sets.
- Prompt caching explained: how it works and how much it saves
What prompt caching is, how OpenAI, Anthropic, Google and DeepSeek do it, minimum lengths, lifetimes, prices and how to structure prompts to cut your API bill.
- Reasoning models: what thinking tokens are and what they cost
What a reasoning model is: how thinking works in OpenAI, Claude, Gemini and DeepSeek, why you pay for reasoning you never see and how to control its depth.
Other topics

Assistants & Chatbots
21 guides

LLM APIs & Costs
16 guides

Local Models & Hardware
16 guides

Language Models Explained
18 guides