TryLLMCost
Zero-Login · 25 Models · Prompt Caching & SaaS Margin Checks

LLM API Cost Calculator, Live Token Counter & AI Agent Margin Studio

Paste any prompt to compare exact token costs across OpenAI, Claude, Gemini, DeepSeek, Llama 4, Mistral & Grok 3 — or simulate multi-step agent gross margins with 80/20 model routing.

100% Client-Side PrivacyInline Editable Rates
Reference public API rates (2025–2026) — editable inline
Load sample:
69 tok
76 tok
~432 tok
50%
0–90%
Async Batch API (24h SLA)
Live Token EstimatorEnglish Prose
OpenAI (o200k)
145
Claude (~1.08x)
157
Gemini (~1.03x)
149
Input Words
107
Characters
660
Out Tokens
432
Cheapest Match (1k calls):Llama 3.1 8B Instant (Groq) · $0.04
#Model & ProviderContext / SpeedInput $/1M (edit)Output $/1M (edit)Cached $/1M1 Call1,000 Calls100,000 Callsvs GPT-4o
1
Llama 3.1 8B Instant (Groq)
Meta (Groq)·Fast / Budget
128K ctx
560 tok/s
N/A$0.000044$0.04$4.39-99%
2
Gemini 2.0 Flash-Lite
Google·Fast / Budget
1.0M ctx
210 tok/s
$0.019$0.0001$0.14$14.05-97%
3
Mistral Small 3.1
Mistral·Fast / Budget
128K ctx
150 tok/s
N/A$0.0002$0.16$15.71-97%
4
Llama 4 Scout 17B (Groq)
Meta (Groq)·Fast / Budget
131K ctx
460 tok/s
N/A$0.0002$0.17$16.93-96%
5
GPT-4.1 nano
OpenAI·Fast / Budget
1.0M ctx
170 tok/s
$0.025$0.0002$0.18$18.19-96%
6
Grok 3 Mini
xAI·Reasoning
131K ctx
155 tok/s
$0.075$0.0002$0.25$24.82-95%
7
GPT-4o mini
OpenAI·Fast / Budget
128K ctx
135 tok/s
$0.075$0.0003$0.28$27.55-94%
8
Gemini 2.5 Flash
Google·Balanced
1.0M ctx
165 tok/s
$0.037$0.0003$0.28$28.10-94%
9
Llama 4 Maverick (Together)
Meta (Together)·Balanced
1M ctx
140 tok/s
N/A$0.0004$0.42$42.24-91%
10
Llama 3.3 70B (Groq)
Meta (Groq)·Balanced
128K ctx
280 tok/s
N/A$0.0004$0.45$44.83-90%
11
DeepSeek V3 (Chat)
DeepSeek·Balanced
128K ctx
68 tok/s
$0.070$0.0005$0.51$51.03-89%
12
GPT-4.1 mini
OpenAI·Fast / Budget
1.0M ctx
115 tok/s
$0.10$0.0007$0.73$72.75-84%
13
DeepSeek R1
DeepSeek·Reasoning
128K ctx
54 tok/s
$0.14$0.0010$1.02$101.68-78%
14
Amazon Nova Pro (Bedrock)
Amazon·Balanced
300K ctx
98 tok/s
$0.20$0.0015$1.51$151.23-67%
15
Claude 3.5 Haiku
Anthropic·Fast / Budget
200K ctx
120 tok/s
$0.080$0.0019$1.94$193.71-58%
16
OpenAI o4-mini
OpenAI·Reasoning
200K ctx
95 tok/s
$0.28$0.0020$2.00$200.05-56%
17
Mistral Large 2
Mistral·Frontier
128K ctx
65 tok/s
N/A$0.0031$3.14$314.20-32%
18
GPT-4.1
OpenAI·Frontier
1.0M ctx
78 tok/s
$0.50$0.0036$3.64$363.72-21%
19
OpenAI o3
OpenAI·Reasoning
200K ctx
52 tok/s
$0.50$0.0036$3.64$363.72-21%
20
Gemini 2.5 Pro
Google·Reasoning
1.0M ctx
88 tok/s
$0.31$0.0046$4.57$456.64-1%
21
GPT-4o
OpenAI·Frontier
128K ctx
85 tok/s
$1.25$0.0046$4.59$459.19Baseline
22
Grok 3
xAI·Frontier
131K ctx
74 tok/s
$0.75$0.0069$6.89$689.25+50%
23
Claude Sonnet 4
Anthropic·Frontier
200K ctx
72 tok/s
$0.30$0.0073$7.26$726.41+58%
24
Claude 3.7 Sonnet
Anthropic·Frontier
200K ctx
75 tok/s
$0.30$0.0073$7.26$726.41+58%
25
Claude Opus 4
Anthropic·Frontier
200K ctx
42 tok/s
$1.50$0.04$36.32$3,632.02+691%

Tip: Click any Input or Output $/1M cell to test custom enterprise discounts, Bedrock/Vertex tiers, or Gemini 2.5 Pro >200k long-context rates inline.

Multi-Script Token Accuracy

Stop relying on naive “4 chars = 1 token” math. Detect dense JSON/code syntax and CJK scripts live across OpenAI o200k_base, Claude, and Gemini tokenizers.

Prompt Caching & 80/20 Routing

Model Anthropic's 90% cache read discount, OpenAI's 75% auto-cache, 50% Batch APIs, and hybrid 80% Flash / 20% Frontier routing in seconds.

Protect 70%+ SaaS Gross Margins

Translate agent steps and MAU directly into Cost per Active User and Gross Margin % against your Stripe plan price — with instant <70% margin alerts and CSV exports.

Dedicated Workload & Model Calculators

20 Pre-Configured LLM Cost & Margin Calculators

Browse full directory

Provider Calculators

Head-to-Head Comparisons

Caching & Batch Savings

Agent & SaaS Workloads

RAG Architecture Costing

RAG Pipeline Token Cost Calculator (Chunking, Rerank & Generation)

Model how top-k retrieved chunks (5–20 chunks x 500 tokens) inflate input token spend — and compare GPT-4.1, Gemini 2.5 Flash, Claude Sonnet 4, and DeepSeek V3.

Open pre-loaded calculator
Agent Loop Economics

AI Agent Multi-Step Token Burn & Unit-Economics Estimator

Model compounding context growth in autonomous multi-step AI agents — and test 80% Fast / 20% Frontier routing before your SaaS margins collapse.

Open pre-loaded calculator
Support Automation ROI

AI Customer Support Chatbot LLM Cost Calculator

Estimate per-ticket and monthly API bills for Intercom/Zendesk-style AI support bots across 25 LLMs and verify margin against seat or resolution pricing.

Open pre-loaded calculator
Developer Tooling Economics

Coding Agent Token Burn Calculator (Cursor / Claude Code / Devin Style)

Simulate heavy developer coding-agent sessions (15k–40k input tokens x 12 tool turns) and see why prompt caching + model routing decide profitability on $20–$40/mo IDE plans.

Open pre-loaded calculator
Document Processing Cost

PDF Summarizer & Long-Document LLM Cost Calculator

Estimate token counts (~500–700 tokens per dense PDF page) and compare exact per-document API cost across 128k and 1M-context LLMs.

Open pre-loaded calculator
Voice AI & Low-Latency LLM

Voice AI & Low-Latency LLM Cost Calculator (Per-Minute Economics)

Estimate the LLM slice of a 5-minute or 15-minute AI phone call across ultra-fast Groq Llama models, Gemini 2.5 Flash, and GPT-4o mini.

Open pre-loaded calculator
AI SaaS CFO Tool

AI SaaS Gross Margin & Unit Economics Calculator

Plug in your Monthly Active Users, agent runs, and SaaS subscription price to get an instant gross-margin health check (<70% alert) across every major LLM.

Open pre-loaded calculator
Transparent SaaS Pricing

Free Forever Calculator. Upgrade When Spend Scales.

Model 25 LLMs with zero login today. Upgrade to Pro or Team for automated API price-drop alerts, saved CFO scenarios, and live usage overrun guards.

Free

No Signup
$0/ forever

Everything you need for architecture sizing, prompt tokenization, and SaaS margin checks.

  • Unlimited comparisons across 25+ models
  • Live client-side prompt token counter (EN/Code/CJK)
  • Prompt caching (0–90%) & Batch API 50% toggles
  • AI Agent & SaaS Gross Margin Simulator
  • 80/20 Model Routing Optimizer + inline rate edits
  • Unlimited CSV financial exports
Use Free Calculator Now
Most Popular

Pro

Founders & PMs
$15/ month

Never get blindsided by provider price changes or margin erosion across investor reviews.

  • Everything in Free, plus cloud-saved scenarios
  • Compare multiple multi-agent architecture versions
  • Weekly API price-drop & new-model email alerts
  • 1-click branded CFO / Board Deck PDF export
  • Custom enterprise discount profiles (AWS/Vertex/OpenAI)
  • Historical token price tracker & depreciation notices

Team

Live Guardrails
$39/ month

Connect real production token telemetry and catch runaway agent loops before the bill lands.

  • Everything in Pro for up to 10 team seats
  • Zero-latency live usage telemetry proxy endpoint
  • Real-time Slack & webhook budget overrun alerts
  • Per-customer / per-tenant gross margin leaderboard
  • Automatic anomaly detection on infinite agent loops
  • Scheduled weekly FinOps digest to #ai-infra

Frequently Asked Questions

How accurate is TryLLMCost's live token counter and API pricing?

TryLLMCost runs a multi-script subword heuristic in your browser covering English prose, source code/JSON syntax density, and CJK scripts with per-provider multipliers (OpenAI o200k_base, Claude ~1.08x, Gemini ~1.03x). All 25 model rates reflect curated 2025–2026 public API rates and can be edited inline for enterprise contracts.

Does TryLLMCost upload or log the prompts I paste?

Never. Token counting, prompt caching simulation, gross margin calculations, and CSV exports execute 100% client-side inside your browser.

How does the AI Agent & SaaS Gross Margin Simulator catch margin traps?

Enter your MAU, runs per user, average steps per agent run, token volume, prompt cache hit rate, and monthly SaaS price. TryLLMCost computes exact monthly API bills and flags any model pushing gross margin below 70%, then models an 80/20 Fast + Frontier routing split to recover margin.

Which LLM providers are included in the 25-model comparison?

We cover OpenAI (GPT-4.1, 4.1 mini/nano, GPT-4o, 4o-mini, o3, o4-mini), Anthropic (Claude Sonnet 4, 3.7 Sonnet, Opus 4, Haiku 3.5), Google (Gemini 2.5 Pro, 2.5 Flash, 2.0 Flash-Lite), DeepSeek (V3, R1), Meta Llama 3.3 & Llama 4 via Groq/Together, Mistral (Large 2, Small 3.1), xAI (Grok 3, Grok 3 Mini), and Amazon Nova Pro.