AI Agent Cost Calculator

Calculate the total monthly cost to run an AI agent including model calls, tools, hosting and human review

Pricing limits: Catalog-rate estimates only — this tool does not automatically select long-prompt pricing tiers. Comparisons, rankings and savings may change at higher tiers. For tier-aware estimates of supported Anthropic Haiku 5.5 and xAI models, use the AI API Cost Calculator. Prompt thresholds count uncached plus cached input tokens per request, not monthly volume. Cache writes/storage, tool charges and batch/priority rates are excluded unless explicitly stated. Announced Google price increases are a warning, not current rates: verify the effective date on the official pricing page.
How to use this tool: Choose the model, describe one complete agent run, then add tool, infrastructure, and review costs. Start with recent traces if you have them; otherwise use the defaults and adjust each assumption. Tap ⓘ for guidance.

Model Selection

Agent Loop

Top-level agent invocations per day

Planning + tool + synthesis steps

Tool & API Calls

Search, web fetch, code exec, etc.

Average 3rd-party API cost

$

Infrastructure (Monthly Fixed)

Server, functions, orchestrator

$

Embeddings, memory, cache

$

Human-in-the-Loop Review

min
$

0 = fully autonomous

%
Source: Official provider documentation. Estimates are informational.

What this tool helps you decide

This calculator helps you decide whether an AI agent is viable at your expected scale by exposing its total cost of ownership — not just the model bill. Agents plan, call tools, read results, and iterate, so the headline per-token price is only one line item. Seeing the full breakdown lets you judge whether the per-run cost supports your pricing or internal budget, and which component to attack first if it doesn’t.

How to use the result

Focus on the variable cost per run — it’s the number that scales with usage and the one that determines whether the agent is sustainable. Compare it against the value each run delivers (a resolved ticket, a completed task). Then look at the breakdown: if model cost dominates, revisit calls-per-run and prompt size; if tool or review cost dominates, the model choice is not your problem. Re-run with a pessimistic calls-per-run figure to see your worst-case exposure, since agent loops are non-deterministic.

Why inference price is not total cost of ownership

A realistic agent budget spans several cost categories that a simple API estimate ignores:

  • Model inference: tokens across every LLM call in the loop — usually multiplied by 5–15 calls per run, not one.
  • Tools & search: web search, retrieval, code execution, and third-party APIs the agent invokes.
  • Orchestration & hosting: the servers or functions that run the agent loop and manage state.
  • Storage: vector databases, memory, and caches that back retrieval.
  • Evaluation: test harnesses and offline runs to catch regressions before they ship.
  • Observability: tracing and logging to debug why an agent behaved as it did.
  • Human review: the reviewer time for runs that need a person in the loop.

Because a single user request fans out into many calls, the multiplier — not the per-token price — is often what makes or breaks the economics.

Illustrative cost-structure scenarios

These show how the dominant cost shifts between agent designs. They are illustrative planning structures, not measured benchmarks or price quotes.

Lightweight lookup agent

Answers a question with one or two tool calls and a short synthesis step.

Illustrative planning assumptions — not provider benchmarks
  • Few LLM calls per run
  • Small inputs and outputs per call
  • Cheap or free tool calls
  • Fully autonomous — little or no human review

What this suggests: Model inference dominates but stays small. Fixed hosting can be the largest share at low volume, so utilisation matters more than model price.

Research agent with search

Iterates across multiple searches, reads results, and synthesises a report.

Illustrative planning assumptions — not provider benchmarks
  • Many LLM calls per run reading growing context
  • Paid search/tool calls on every run
  • Larger inputs as context accumulates
  • Occasional human spot-checks

What this suggests: Tool costs and compounding context can rival or exceed base inference. Caps on iterations and search calls are the highest-leverage controls.

High-stakes reviewed agent

Drafts customer-facing or compliance-sensitive output that a person approves.

Illustrative planning assumptions — not provider benchmarks
  • Moderate LLM and tool costs
  • A meaningful share of runs routed to human review
  • Reviewer time priced at a loaded hourly rate

What this suggests: Human review often becomes the single largest line item. Reducing the review fraction safely — via better evaluation — beats squeezing token cost.

Decision factors & limitations

  • Agent token usage is non-deterministic; a single run can loop and consume far more than the average, so enforce hard call and token limits.
  • Tool and infrastructure costs here are your own inputs — validate them against your actual providers.
  • Evaluation and observability tooling costs are real but vary widely; fold them into hosting or add them separately.
  • Model prices are standard pay-as-you-go and exclude enterprise, batch, and committed-use discounts.
  • Official sources are checked on a recurring schedule. Unusual or structural changes are held for human review.

Sources & methodology

See how model prices are sourced and reviewed, and which providers are currently verified:

How this calculation works

Agents consume far more tokens than simple chatbots because they plan, call tools, read outputs, and iterate — often making 5–15 LLM calls per user request. This calculator models a complete agent loop: LLM calls × tokens per call, plus third-party tool costs (search, APIs), fixed infrastructure (hosting, vector DB), and any human-in-the-loop review time. All costs are aggregated to give you a realistic monthly and annual total.

Frequently Asked Questions

What's a typical number of LLM calls per agent run?
A simple ReAct agent answering a question might need 3–5 calls. A complex research or coding agent can use 10–20 calls — reading context, planning, calling tools, evaluating results, and synthesising an answer. Start with 5 and adjust based on your traces.
Why are agent costs so much higher than direct API costs?
The compounding effect of multiple LLM calls is the main driver. If each call uses 2,000 input + 500 output tokens and you make 5 calls per run, that's 10,000 input + 2,500 output tokens per user request — 5× the naive estimate.
How do I estimate third-party tool call cost?
Web search APIs (SerpAPI, Brave, Tavily) typically cost $0.001–$0.01 per search. Vector DB queries are usually free within a generous tier. Code execution sandboxes vary. Start with $0.002 as a conservative average if you use a mix.
What is the review fraction?
The percentage of agent runs that trigger a human-in-the-loop review step before the output is sent to the end user. If 10% of runs require a 2-minute review at $60/hr, that adds $0.20 per reviewed run.