Free calculator · no sign-up
What will your AI agent cost to run?
Paste your LangGraph, CrewAI or OpenAI Agents SDK code, or a Flowise export. See the cost of every step, the monthly bill at your traffic, and the model swaps that cut it. Before you run or deploy anything.
- Your code stays in your browser
- Provider list prices
- Python, JS/TS and Flowise
Longer inputs mean more tokens in every step.
Per run
$0.016
3.2k tokens
Per month · 1,000/day
$493
30 days
With cheaper models
$169
per month, 66% less
Where the money goes
- Replyclaude-sonnet-4-5 · 904 in / 400 out$0.0087$261/mo
- Researchclaude-sonnet-4-5 · 487 in / 400 out$0.0075$224/mo
- Triagegpt-4o-mini · 96 in / 400 out$0.0003$7.63/mo
Cheaper plan
Move these steps down one tier. Untick any step that needs the stronger model.
Check quality before you ship it: open the agent in the editor, add a few test cases and run them before and after. Cost and pass rate show side by side.
What the numbers assume
- Input is each step's real prompt: its instructions, the task and what earlier steps pass on, at about 4 characters per token.
- Replies can't be known before a run, so 3 model steps are assumed to write about 400 tokens (roughly 300 words). Set "Reply length" on a step to change it.
- Tools cost nothing themselves; each search or fetch result is assumed to add about 500 tokens to the next step's input.
- Priced at list price for gpt-4o-mini, claude-sonnet-4-5.
- Every step is counted once, including each side of a branch.
- Loop Tools → Research is counted once; each extra pass adds to the bill.
Estimate before you run, track after
Tracing tools such as LangSmith and Langfuse report cost once an agent has served real traffic. Visual builders such as Dify, n8n and Flowise don't estimate cost at all. This calculator reads the code you already have and prices every step before anything runs, so you can pick models with the bill in front of you.
Nodagentry is free to try: open the result in the editor to run it, apply a fix and compare before and after, or add the CI cost check so a pull request that makes your agent pricier gets flagged.
Price tiers
Known models use their list price. A model the calculator doesn't know is priced at its tier's typical rate. The cheaper plan moves Frontier and Frontier Pro steps down one tier.
| Tier | Models in your code | Typical per 1M in / out |
|---|---|---|
| Frontier Pro | claude-opus-4-1, o3, gpt-4.5 | $15 / $60 |
| Frontier | gpt-4o, gpt-4.1, claude-sonnet-4-5, gemini-2.5-pro | $2.5 / $10 |
| Frontier Mini | gpt-4o-mini, claude-3-5-haiku, gemini-2.5-flash, o3-mini | $0.8 / $3.2 |
| Open 70B | llama-3.3-70b, mixtral-8x7b, qwen2.5:72b | $0.4 / $0.8 |
| Local 7B | llama3.1:8b, qwen2.5:7b, mistral | $0.05 / $0.1 |
Well-known GPT, Claude, Gemini and Grok models are priced at their own list price (checked 2026-10-21). The tier price is used for any other model on that tier.
Questions
- How much does an AI agent cost to run?
- It depends on how many model calls one run makes, how long each prompt and reply is, and which model each step uses. A three-step agent on a mini model can cost a fraction of a cent per run, while the same agent on a frontier reasoning model can cost a hundred times more. Paste your code above to see your own numbers per step.
- Is my code uploaded or run?
- No. The calculator reads your code as text in your browser to find agents, tools, branches and models. Nothing is executed and nothing is sent to a server.
- How accurate is the estimate?
- Input tokens are counted from the prompts in your code, the typical input you give and what earlier steps pass on, at about 4 characters per token. Replies can't be known before a run, so each model step is assumed to write about 400 tokens. Well-known models are priced at their provider's list price (checked 2026-10-21). Loops count as one pass, so an agent that calls tools several times will cost more. Run it in the editor with your own key to see real token counts.
- Will a cheaper model be good enough?
- Often, for steps like routing, triage and summarising; less often for the step that does the hard reasoning. Open the agent in the editor, add a few test cases with the facts each answer must contain, and run them before and after the swap. The compare view shows cost and how many cases still pass side by side.
- How is this different from LangSmith or Langfuse cost tracking?
- LangSmith and Langfuse report what your agent cost after it has served real traffic, and need an account and SDK setup first. This calculator estimates the cost from your code before you run or deploy anything, and shows which model swaps would cut it. They work well together: estimate here, then track real spend there.