Resources, Costs
AI agent costs: how to budget, set limits and measure value
AI agents are billed by the token, and a single task can call a model dozens of times. This guide explains how model pricing works, what makes agent costs grow, and how to set budgets that warn early and stop spending at a limit.
Updated 20 November 2026. 9 minute read.
In short
- Providers charge per token, with separate prices for input and output. Output tokens cost more than input tokens on the published price lists of major providers, and prices differ widely between models.
- Agent costs are driven by loops: each step resends the growing context, so input tokens often dominate the bill. Tools, long documents, retries and reasoning tokens add to it.
- Set budgets at three levels: company, agent and project. Warn at a threshold, for example 80%, and pause work at the limit.
- Route simple steps to cheaper models, and use caching and batch processing where providers offer discounts.
- Measure cost per completed task against the value of the work, not total spend alone.
How model pricing works
Language models read and write text in tokens, which are short pieces of words. Providers such as OpenAI and Anthropic publish prices per million tokens, mostly in US dollars. Each request is billed on two counts:
- Input tokens: everything sent to the model, including instructions, conversation history, documents, tool definitions and tool results.
- Output tokens: everything the model writes back.
On the published price lists of OpenAI and Anthropic, output tokens cost more per token than input tokens. Prices also vary widely between models from the same provider. Larger, more capable models cost a multiple of smaller ones. Prices change often, so check the official pricing page on the day you plan.
Hidden tokens and discounts
- Reasoning tokens. OpenAI states that reasoning tokens are not shown in the response but are billed as output tokens. Anthropic states the same for extended thinking.
- Tool definitions. Anthropic counts the names, descriptions and schemas of the tools you give a model as input tokens on every request.
- Prompt caching. Both providers charge less for input that is read from a cache, such as fixed instructions repeated on every call. Anthropic charges more than the normal input price to write to the cache.
- Batch processing. Both providers offer a batch interface at 50% of standard prices, for work that can wait up to 24 hours.
A worked example
All numbers in this example are hypothetical. They show the mechanics, not any provider's real prices.
Assume Model A costs €2 per million input tokens and €10 per million output tokens. An agent handles a task in 10 steps. The first step sends 5,000 tokens of instructions and data. Each step adds 2,000 tokens of tool results and output to the context, and the model writes 500 tokens per step.
- Input per step grows from 5,000 to 23,000 tokens. Over 10 steps that is 140,000 input tokens, costing €0.28.
- Output is 10 × 500 = 5,000 tokens, costing €0.05.
- One task costs €0.33. At 1,000 tasks a month, that is €330.
Two lessons follow. First, input dominates. Output is more expensive per token, yet it makes up only about 15% of this bill, because the context is resent at every step. Second, model choice moves the total most. If Model B costs one tenth as much and handles the task well, the same month costs €33.
Now add one failure. If the agent retries the whole task once in every five runs, the monthly cost rises by 20%. If it loops without a step limit, there is no ceiling at all.
What drives cost in agents
A chat answer is one request. An agent plans, calls tools, reads results and tries again. Each of those is another request. The main drivers are:
- Loops. Each step is a new model call. Anthropic's documentation describes how earlier turns stay in the context window, and OpenAI counts input, output and reasoning tokens in the context total. Longer tasks therefore cost more than in proportion to their length.
- Context length. Long documents, full email threads and large tool results inflate every later step. Summarise or trim before passing data on.
- Tools. Each tool definition adds input tokens, and each tool result is fed back into the context.
- Retries. Errors, timeouts and failed checks repeat work that has already been paid for.
- Reasoning effort. Models that reason before answering produce more output tokens, which are billed even when hidden.
Providers give some controls. OpenAI's max_output_tokens setting caps generated tokens, including reasoning tokens. But a cap on one request does not cap a loop of many requests. That needs a budget.
Budgets, warnings and hard limits
Set budgets where decisions are made. Three levels work for most companies:
- Company: the total monthly amount for AI usage, agreed with finance.
- Agent: a limit for each agent, matched to its role. A research agent and an email triage agent need very different amounts.
- Project: a limit for a piece of work with a start and end, such as a migration or a campaign.
Warnings and stops
A budget without a warning arrives as a surprise. A budget without a stop is only a forecast. Use both:
- Warn the responsible employee at a set share of the budget, for example 80%, so there is time to act.
- Pause the agent or project at the limit, so work stops instead of spending more.
- Let an employee with authority raise the limit or resume work, and record that decision.
- Add a maximum number of steps per task, so a single runaway loop cannot use a whole month's budget.
Check also whether your AI provider accounts offer their own usage limits, as a second safety net.
Use cheaper models for simple steps
Not every step needs the most capable model. Many agent steps are routine: classifying an email, extracting fields from an invoice, checking a format or summarising a short text. A smaller model often handles these well at a fraction of the cost.
- Split tasks into steps and assign a model per step, keeping the most capable model for planning and judgement.
- Test each step on a small set of real examples before moving it to a cheaper model.
- Cache fixed instructions and reference text that repeat on every call, where your provider supports it.
- Send work that can wait, such as nightly reports or bulk classification, through batch processing.
- Trim context: pass summaries and the relevant parts of documents, not everything.
Keep the choice reversible. Model prices and quality change with each release, so re-run your tests when a provider launches or retires a model.
Measure value against cost
Total spend says little on its own. Measure cost per unit of useful work:
- Cost per completed task: model spend divided by tasks finished and accepted.
- Acceptance rate: the share of agent output that employees approve without major changes.
- Employee time: minutes spent reviewing and correcting, compared with doing the task by hand. Measure it on a sample, not by guesswork.
- Outcome measures that already exist in the business, such as response time to customers or backlog size.
A cheap agent whose output is mostly rejected is expensive. A costly model that finishes work employees accept on the first pass can be good value. Review these figures monthly, together with the budget.
The checklist
- Read the current pricing pages for every model you use, and note the date.
- Estimate cost per task from tokens per step, number of steps and price, as in the worked example.
- Set a monthly company budget, and limits per agent and per project.
- Warn at a threshold, such as 80%, and pause at the limit.
- Cap steps per task and output tokens per request.
- Assign cheaper models to simple steps after testing them.
- Use caching and batch processing where they fit.
- Trim context and tool results before they are passed on.
- Track cost per accepted task and employee review time.
- Review spend, limits and model choices every month.
How Blentera helps
Budgets warn at 80% and pause agents at the limit. Each agent has a role in the org chart, approval rules decide what needs an employee's sign-off, and the activity log shows what agents did. You connect your own AI provider accounts (OpenAI, Anthropic, xAI, or Gemini, Mistral and others through OpenRouter) and pay providers directly, with no markup. Plans: Free €0, Business €199 a month per company, Enterprise custom.
Questions
- Providers set the prices. On the published price lists of OpenAI and Anthropic, output costs more per token than input. In agents, input often still makes up most of the bill, because the context is resent at every step.
- It depends on the model, the number of steps per task, the context size and the volume of tasks. Estimate tokens per task, multiply by current prices from the provider's pricing page, and add a margin for retries. Then confirm with real usage data.
- There is no legal or industry standard. A threshold such as 80% of the budget leaves time to act before the limit. Pair the warning with a hard stop at 100% so spending cannot continue unnoticed.
- Yes. OpenAI bills reasoning tokens as output tokens, and Anthropic bills extended thinking as output tokens, even when the reasoning text is not shown.
- Use cheaper models for simple steps after testing them, trim context, cache repeated instructions, batch work that can wait, and cap steps per task. Track cost per accepted task to check quality holds.
Sources
Related
This guide is general information, not legal advice. Check how the rules apply to your company with your own advisers.
Get started
Put your first agent to work in minutes.
Three steps, and your first agent is working for your company.
Step 1
Create an account
Sign up with your work email and invite your team. No sales call needed.
Step 2
Add your first agent
Create an agent, give it a role, and connect your own AI key and the apps it may use.
Step 3
Give it a task
Ask in Blentera or your chat app, and follow the work until it is done.