← All Tools

LLM API Cost Calculator

Estimate per-request and monthly cost across major LLM providers. Customize input / output / cached pricing, see what prompt caching saves, and compare every model in one click.

Usage

"Cached input tokens" use cache-read pricing if the provider supports it. The remaining input tokens (input − cached) use the standard input rate. Markup multiplies the final cost — useful if you bill customers a margin on top of raw API spend.

Selected model

Prices are editable — tweak them to match your contract or pre-release pricing. The presets below load known list prices but providers update these often, so always sanity-check against the provider's pricing page.

Cost summary

Compare all models

Same usage applied across every preset. Click any row to load its prices into the form above.

ModelProvider $/call $/day $/month

How the math works

Cost per call = (input − cached) × pin/1M + cached × pcacheRead/1M + output × pout/1M. The "no cache" comparison ignores cache-read pricing and bills every input token at the full input rate. Daily cost = per-call × calls/day; monthly cost = daily × active days. Markup applies last. Tokens are provider tokens, not characters — for a rough estimate, English text averages ~4 characters per token.