MCP Tool Schema Token Cost Calculator
Every tool an MCP client loads is described to the model on every request. Add a few servers and the tool block can reach tens of thousands of tokens before the user has typed a word. This calculator shows what that costs in context and money.
Your numbers
All tools loaded across every connected MCP server.
Name, description and parameter schema. Count a sample with your model's tokenizer.
Every turn of a conversation counts as a request.
Use your provider's current price. For self-hosted models, use your internal cost per million.
Prompt caching of the stable tool block, if your provider supports it.
Check your provider's current cached-input pricing.
Your results
An estimate. Real token counts depend on the model tokenizer and schema detail, and provider pricing and caching rules change. Treat results as a planning range.
Tool definition tokens vs tools exposed
Sweeps Tools exposed to the model from 1 to 100, holding your other inputs fixed.
Slim down my tool layer
Optionally request advice on splitting or trimming your MCP tool set.
Optional. The tool and every export work without this. No spam.
How to use the calculator
Set the number of tools across all connected servers, not just one. Estimate the average tokens per definition by pasting two or three real tool definitions into your model's tokenizer and averaging. Enter daily requests, counting each turn of a conversation, then your input price. If your provider caches stable prompt prefixes, set the cached share and discount. The results show tokens per request, share of the context window, monthly volume and monthly cost.
The formula
Tool definition tokens equal tool count times average tokens per tool. Monthly tokens equal that figure times daily requests times thirty. Cost equals monthly tokens divided by one million, times the input price, times the effective billed share. The effective share is one minus cached share times cache discount, so a 90 percent discount on 80 percent of requests bills about 28 percent of the full amount. The chart sweeps tool count to show the linear growth.
Reading the result
With 24 tools at 250 tokens, the block is 6,000 tokens per request, under 5 percent of a 128,000 token window. Fine on its own, but the cost compounds with traffic, and the harder penalty is accuracy: models choose less reliably when many similar tools compete. If the share passes 10 to 15 percent, consider splitting servers by domain, loading tools on demand or shortening descriptions.
- Split servers by domain so each agent sees fewer tools
- Shorten descriptions but keep enums and units explicit
- Use caching for the stable tool block where supported
- Remove tools nobody has called in a month
Common mistakes
People count only their own server and forget the others loaded by the client. They also estimate tokens from character counts, which varies a lot for JSON schemas, and forget that multi-turn agents resend the block on every turn. Finally, optimizing for cost alone can strip the descriptions that make tool selection accurate, so re-run your evaluation set after any trimming.
Frequently Asked Questions
How many tokens does a typical MCP tool use?
It varies widely. A simple tool with two parameters may be under 100 tokens, while one with many parameters and long descriptions can exceed 500. Measure a few of yours with your model's tokenizer.
Does prompt caching apply to tool definitions?
Many providers can cache a stable prompt prefix, which often includes tool definitions. Rules, minimum sizes and discounts differ and change, so check your provider's current documentation.
Is there a limit on how many tools I should expose?
No universal limit, but accuracy tends to fall as similar tools multiply. Keep each agent's toolset focused and split large catalogs by domain.
Does this apply to self-hosted models?
Yes for context and latency. Use your internal cost per million tokens in the price field, or set it to a GPU-hour based estimate.
Netray designs agent tool layers over ERP to be small and well described. If your tool block is bloating prompts, we can help restructure it.
Related Tools
MCP Tool Catalog and Risk Worksheet
Register each MCP tool your agent exposes, the ERP object it touches and a computed risk score, then export to Excel.
Developer ToolsERP API Field Mapping Worksheet
Map each ERP API field to the parameter an AI tool exposes, with types, required flags and transform rules, then export to Excel.
Developer ToolsMCP Server Deployment Runbook Template
A fill-in runbook covering host, secrets, network, health checks, monitoring and rollback for an MCP server in front of an ERP.
AI Agents & AutomationAI Agent Evaluation Test Case Worksheet
Log evaluation questions for an ERP agent with expected answers, the tool it should call and scored results, with a computed pass rate.
More Developer Tools tools
See all- SAP Sales Order ABAP SELECT Generator (VBAK, VBAP, VBFA)
- SAP Sales Order Create BAPI ABAP Generator (BAPI_SALESORDER_CREATEFROMDAT2)
- SAP ABAP Open Items SELECT Generator
- SAP ACDOCA SQL Query Generator
- SAP QM Inspection Lot ABAP SELECT Generator
- SAP Quality Notification Pareto SQL Query Generator
- SAP QM Usage Decision BAPI Skeleton
- ABAP Custom Exception Class Generator
- ABAP Unit Test Class Generator