Cost formula
Chat cost = sum over turns of (input tokens including history / 1M × input price) + (output tokens / 1M × output price); Completion cost = (prompt tokens / 1M × input price) + (output tokens / 1M × output price)
Calculator
See how growing chat history changes your bill compared with stateless completion-style requests on the same model.
Chat vs completion
$0.0055731.3% gap
Completion wins when chat history balloons — each turn re-bills prior context as input.
Workloads
Chat re-sends growing history; completion stays stateless.
Token shape
Completion wins when chat history balloons — each turn re-bills prior context as input.
Completion wins when chat history balloons — each turn re-bills prior context as input.
Chat cost grows with history because prior turns are usually re-sent as input. Rates updated 2026-07-31. Approximate static list prices for planning only. Always verify against each provider’s official pricing page before production budgeting.
Guide
Compare chat-style API usage against legacy completion-style calls for the same workload. Chat endpoints carry message overhead and often repeat system context each turn, which can inflate input tokens at monthly volume. Use this to decide which API shape fits your product and budget.
Chat cost = sum over turns of (input tokens including history / 1M × input price) + (output tokens / 1M × output price); Completion cost = (prompt tokens / 1M × input price) + (output tokens / 1M × output price)
Chat APIs simplify product logic but can multiply input tokens when conversation history grows. Teams that assume chat and completion cost the same often miss the compounding effect of multi-turn context on monthly bills.
Not always. Short single-turn chats with small history can match completion cost. Multi-turn threads with growing context usually cost more unless you truncate history or use caching.
Most providers bill the same per-token input and output rates regardless of endpoint. The cost difference comes from token volume, not a separate chat surcharge.
Estimate active sessions per day, average turns per session, and tokens per turn. Multiply out to monthly input and output totals, then apply list prices as a planning estimate only.
No. All numbers are approximate planning aids based on static list prices. Confirm official pricing before production budgeting.