aiapicostcalcUnit economicsPricesBrandsCompareBenchmarksSkills & PluginsFind my modelGuidesChanges

n8n AI agent token cost: per workflow and per month

Short answer: n8n AI Agent burns about 45K input tokens (50% cached) and 2,500 output tokens per typical task, so one task costs $0.0712 on Grok 4.7. At 500 tasks a month that is $35.62; without caching the same task would cost $0.1050. Evidence: measured.

Last verified 2026-11-18 · Sources: src/tools.json (n8n AI Agent token basis, measured) and src/prices.json (rates) · Report an error

By Shangyi Duan · Tool token basis: Measured

Tool token data: src/tools.json (reviewed 2026-11-05) · Model rates: src/prices.json (checked 2026-11-18) · Evidence: Measured

Cost per task, three price points

One row per scenario from our tool data. The three price columns price the identical token counts on the cheapest, mid and premium reference models, so the difference is the model rate, not the workload.

ScenarioInput tokensCached inputOutput tokensCheapest current modelMid-tier reference modelPremium reference model
Light task
one short request with a small context and one or two tool calls
10K30%800$0.00113$0.0203$0.2260
Typical task
one coding or agent task with several tool calls and a medium context
45K50%2,500$0.00373$0.0712$0.7450
Heavy session
a multi-turn agent session with a large repo or long history; input counts all tokens re-sent across turns
150K60%6K$0.0099$0.2010$1.98

Rates: input $2 / cached $0.5 / output $6 per 1M on Grok 4.7. Prices checked 2026-11-18.

Monthly budget

Scenario at 500 tasks / monthCheapest current modelMid-tier reference modelPremium reference model
Light task$0.5650$10.15$113
Typical task$1.86$35.62$372
Heavy session$4.95$100$990

At 500 tasks a month, one task at the typical size costs $0.0712 on Grok 4.7, so $100 covers about 1404 tasks. The same budget buys 134 tasks on the premium reference and 26846 on the cheapest one.

Recalculate this page in your browser

Server-rendered from the typical task on Grok 4.7 at 500 tasks a month. Change a field to recalculate; nothing is sent anywhere and the formula is the one under Method.

Cost per task
$0.0712
Cost per 1,000 tasks
$71.25
Monthly
$35.62

Where the tokens go

The provider basis behind these numbers

A published n8n debugging case (Classmethod, 2025-12-17) measured an AI Agent context breakdown of 2,000 tokens of system prompt, 3,000 of conversation history, 20,000 of tool/RAG results and 100 for the user question - about 25k input per agent request, with tool results fed back into every later request. The tiers scale that measured per-request cost to 1 step (light), 2-3 steps with tool results (typical) and a multi-turn chatflow with memory (session).

What caching is worth here

Our data does not assume a cached prefix for this tool (50% cached share), so the task price above is already the uncached input price. If the tool does repeat a stable prefix, adding it to the provider cache cuts the input side to $0.5 per 1M on Grok 4.7.

How to reduce it

Each tip changes a different part of the formula: caching changes the input rate, trimming history changes the input count, and routing simple steps to a cheaper model changes the rate for part of the work.

Sources and evidence

SourceRead onWhat it establishes
dev.classmethod.jp2026-11-04Measured n8n AI Agent token breakdown (system prompt, history, tool result) and the workflow change that cut token use.
docs.n8n.io2026-11-04Official n8n AI Agent node documentation: tools, memory and agent architecture.

Evidence label: Measured

A published n8n debugging case (Classmethod, 2025-12-17) measured an AI Agent context breakdown of 2,000 tokens of system prompt, 3,000 of conversation history, 20,000 of tool/RAG results and 100 for the user question - about 25k input per agent request, with tool results fed back into every later request. The tiers scale that measured per-request cost to 1 step (light), 2-3 steps with tool results (typical) and a multi-turn chatflow with memory (session).

Method

The formula

Cost per task = (uncached input × input rate + cached input × cached rate + output × output rate) ÷ 1,000,000. Rates are the standard list prices in the price table (checked 2026-11-18); token counts come from src/tools.json (tool data reviewed 2026-11-05).

Why three reference models

The columns are the cheapest, median and most expensive current models by the cost of one typical agent task, named above so you can check each rate. They are a range, not a prediction of which model n8n AI Agent uses.

What the monthly figure assumes

500 tasks a month (the tasks-per-month field in our tool data), the same count for every scenario, at the standard rate with no batch discount. A heavy session can count as several tasks, so replace the number with your own before you put it in a budget.

Official links

Related skills & plugins

Other entries in the Workflow automation category. Each name links to its token-cost page or its official site.

Related models

The three reference models in the cost table, with their full price tiers.

More

Related

Questions

How much does n8n AI Agent cost per task?

One typical task costs $0.0712 on Grok 4.7, $0.00373 on the cheapest reference model (GPT-6 Luna) and $0.7450 on the premium reference (GPT-6 Cyber). The spread is the model rate: the token counts are identical in all three columns.

What does n8n AI Agent cost per month at 500 tasks?

$35.62 a month on Grok 4.7 at the typical task size. Without the 50% cached input assumption it would be $52.50. Per 1,000 tasks the token bill is $71.25.

Why does n8n AI Agent use so many input tokens?

In n8n (and LangChain-style agents), every tool result is appended to the agent context, so a large RAG or HTTP response can dominate the bill, and each additional tool-call iteration resends the whole context. Memory nodes, system prompts and schema text add a fixed overhead to every request. The token shape is 45K input tokens (50% cached) against 2,500 output per typical task; input is resent every step, output is not.

Are the n8n AI Agent token numbers measured or estimated?

The evidence label is "Measured". A published n8n debugging case (Classmethod, 2025-12-17) measured an AI Agent context breakdown of 2,000 tokens of system prompt, 3,000 of conversation history, 20,000 of tool/RAG results and 100 for the user question - about 25k input per agent request, with tool results fed back into every later request. The tiers scale that measured per-request cost to 1 step (light), 2-3 steps with tool results (typical) and a multi-turn chatflow with memory (session). Sources and read dates are in the table above; if a number is an estimate, the basis says what it assumes, and it is never described as a measurement.

Next step → See every tool cost side by side

Price data last checked 2026-11-18 against official sources · how we verify

Price-change alerts

One short email when a provider changes a price or a promo ends. No spam, unsubscribe any time.