{"slug": "what-an-llm-api-call-really-costs-the-formula-and-four-levers-that-move-the-bill", "title": "What an LLM API call really costs: the formula and four levers that move the bill", "summary": "A developer published a formula and worked examples showing how LLM API bills are driven by input and output token counts, caching, batch pricing and long-context surcharges. Using Claude Sonnet 5.5 and GPT-6.1 Sol at $2 per million input and $10 per million output tokens, a support bot handling 1,000 requests a day at 1,500 input and 400 output tokens costs $210 a month, dropping to $105 with batch pricing and to $120.72 for a 10,000-token cached prompt. Across 65 models, output prices run 1.0x to 10.0x input prices with a median of 5.0x, and on Sonnet 5.5 output is about 21% of tokens but 57% of cost.", "body_md": "Prices are quoted per million tokens, but the bill depends on how many tokens you send, how many you get back, and which pricing rules apply. Figures below were checked against the providers' own pages on 13 November 2026.\n\n`cost = input_tokens / 1e6 * input_price + output_tokens / 1e6 * output_price`, times requests per day, times 30. A support bot sending 1,500 input and 400 output tokens, 1,000 times a day, on Claude Sonnet 5.5 ($2 in, $10 out per million) costs **$210.00 a month**; GPT-6.1 Sol lists the same prices ([Anthropic pricing](https://platform.claude.com/docs/en/about-claude/pricing), [OpenAI pricing](https://developers.openai.com/api/docs/pricing)). You can reproduce it in an [LLM API cost calculator](https://createchz.com/ai-costs/llm-api-cost-calculator/).\n\nAcross 65 models in our price table, output is 1.0x to 10.0x the input price, with a median of 5.0x. On Sonnet 5.5 a chat turn is about 21% output by tokens but 57% of the cost, so trimming replies usually saves more than trimming prompts.\n\nCached reads cost 0.1x the input price on most Claude models and on GPT-5.6 and later, and 0.05x on models such as Sonnet 5.5 and GPT-6.1 Sol; writing a cache entry costs 1.25x ([Anthropic prompt caching](https://platform.claude.com/docs/en/build-with-claude/prompt-caching)). For a 10,000-token fixed prompt at 1,000 requests a day, our worked example falls from $690.00 to $120.72 a month. Minimum prompt lengths apply, so short system prompts will not cache.\n\nAnthropic, OpenAI and Google charge 50% less for jobs that can wait up to a day ([OpenAI Batch API](https://developers.openai.com/api/docs/guides/batch)). The chatbot above falls from $210 to $105 a month.\n\nOpenAI steps up above 272K input tokens, Gemini 3.1 Pro and Grok above 200K, Claude Haiku 5.5 above 100K. A 300K-token prompt costs about $0.61 on Sonnet 5.5 and $6.08 on GPT-6 Astra (our arithmetic from the published prices).\n\nOn three reference workloads, Sonnet 5.5 and GPT-6.1 Sol cost the same; the small tier (Haiku 5.5 or GPT-6 Luna) costs $10.50, $9.00 and $8.52 a month, and flagships run 2 to 3 times the mid tier. Run the same 50 to 100 real prompts through each candidate and divide cost by passing answers. The full table is in this [OpenAI API pricing breakdown](https://createchz.com/ai-costs/openai-api-pricing/) alongside the other providers.", "url": "https://wpnews.pro/news/what-an-llm-api-call-really-costs-the-formula-and-four-levers-that-move-the-bill", "canonical_source": "https://dev.to/gary_walkers_fecd8f641755/what-an-llm-api-call-really-costs-the-formula-and-four-levers-that-move-the-bill-2748", "published_at": "2026-11-14 00:09:31+00:00", "updated_at": "2026-11-14 00:21:55.431923+00:00", "lang": "en", "topics": ["large-language-models", "ai-infrastructure", "ai-tools"], "entities": ["Anthropic", "OpenAI", "Google", "Claude Sonnet 5.5", "GPT-6.1 Sol", "Gemini 3.1 Pro", "Grok", "Claude Haiku 5.5"], "also_reported_by": [], "alternates": {"html": "https://wpnews.pro/news/what-an-llm-api-call-really-costs-the-formula-and-four-levers-that-move-the-bill", "markdown": "https://wpnews.pro/news/what-an-llm-api-call-really-costs-the-formula-and-four-levers-that-move-the-bill.md", "text": "https://wpnews.pro/news/what-an-llm-api-call-really-costs-the-formula-and-four-levers-that-move-the-bill.txt", "jsonld": "https://wpnews.pro/news/what-an-llm-api-call-really-costs-the-formula-and-four-levers-that-move-the-bill.jsonld"}}