Cloud & API FinOps

LLM API Monthly Cost, Prompt Caching & Batch Calculator

Project monthly LLM API bills factoring in prompt cache hit rates, 50% Batch API discounts, and output-to-input token price multipliers.

Input Parameters

reqs/day
tokens
tokens
%
24-hour SLA batch queues cut both input and output rates by 50%.
Calculated Output
Primary Result
—
Adjust inputs to recalculate immediately.

2026 LLM API Rate Card Reference ($ per 1M Tokens)

Representative pricing tiers showing cached prefix discounts and 4x–6x output token cost multipliers.

Model TierInput / 1MCached Input / 1MOutput / 1MIdeal Workload
Budget Flash (DeepSeek V4 Flash / Flash-Lite)$0.10$0.01$0.28–$0.40Extraction, routing, high-volume RAG
Near-Frontier Value (DeepSeek V4 Pro)$0.55$0.02$1.40Coding & complex pipelines on budget
Workhorse (Claude Sonnet 5.5 / Sol / Gemini Pro)$2.00$0.10–$0.20$10.00–$12.00Production agents, synthesis, SaaS UX
Frontier Reasoning (Astra / Opus)$8.00–$10.00$0.80–$1.00$40.00–$50.00Hard architecture, math & deep audits

Formula & Engineering Methodology

Monthly spend splits total input volume into uncached prefix tokens and prompt-cached tokens, then applies output rates and an optional 0.5x Batch API multiplier across 30 days.

monthly_reqs = requests_per_day * 30 total_in_m = (monthly_reqs * avg_input_tokens) / 1e6 cached_m = total_in_m * (cache_hit_pct / 100) uncached_m = total_in_m - cached_m total_out_m = (monthly_reqs * avg_output_tokens) / 1e6 monthly_cost = ((uncached_m * rate_in) + (cached_m * rate_cached) + (total_out_m * rate_out)) * (0.5 if batch_api else 1.0)

Variable Definitions

Practical Note: Prompt caching typically requires minimum prefix lengths (e.g., 1,024 tokens) and consistent prefix ordering (put static system instructions and few-shot examples first).

Frequently Asked Questions

How does prompt caching cut RAG and agent bills by up to 90%?
Long system instructions, tool schemas, and shared knowledge bases stay warm in provider KV caches, dropping input token costs from $2.00/1M down to $0.10–$0.20/1M.
Why do output tokens cost 3x–6x more than input tokens?
Input prefill parallelizes across thousands of GPU cores in one pass, whereas autoregressive output generation executes serially token-by-token, tying up VRAM bandwidth.
When should I switch to Batch API?
Any offline evaluation, document enrichment, classification, or nightly summary job tolerant of 1–24 hour completion times saves a flat 50% with zero model change.

Related Engineering Calculators

ComputeSizer runs 100% locally in your browser with open formulas and zero account gates. If these VRAM and GPU cost tools saved your team money, support us via Fourthwall or sponsor an ad-free developer placement.