OpenAI API cost estimator
GPT Cost Calculator
Calculate GPT API cost for chat, RAG, agents, coding tools, and batch automation. Enter a token mix once, then compare OpenAI model tiers by input, cached input, and output pricing.
OpenAI pricing rule
GPT-5.4 Mini Token Cost Calculator
Estimated API cost
$0.03- Input
- $0.0188
- Cached input
- $0.00
- Output
- $0.0113
- Per 1,000 requests
- $30.00
Cost Per Million Tokens
| Model | Input | Cached input | Output | Context |
|---|---|---|---|---|
| GPT-5.5 | $5 | $0.5 | $30 | Provider dependent |
| GPT-5.4 | $2.5 | $0.25 | $15 | Provider dependent |
| GPT-5.4 Mini | $0.75 | $0.075 | $4.5 | Provider dependent |
GPT vs Claude Pricing Snapshot
How GPT Pricing Works
GPT pricing is usually split into input tokens and output tokens. Input tokens include user messages, system instructions, retrieved documents, schemas, and conversation memory. Output tokens are the model response.
For production apps, the real cost is not one call. Estimate the average request, then multiply by monthly request volume and by the number of model calls per workflow.
GPT Workloads To Model
- Chat apps with conversation history
- RAG answers with retrieved context
- AI coding and code review tools
- Agent loops with multiple model calls
- Batch summarization or extraction jobs
GPT Cost Example
A request with 25,000 input tokens and 2,500 output tokens can look cheap once, but 100,000 monthly requests can turn that pattern into meaningful infrastructure spend. That is why per-1,000-request estimates are often more useful than a single-call estimate.
Pricing source: OpenAI pricing page. Last local rule update: 2026-05-29. Use this estimator for planning, not invoice reconciliation.
FAQ
How do I calculate GPT API cost?
Enter the expected input tokens and output tokens for one request. The calculator multiplies those values by the selected GPT model pricing per million tokens.
What is the difference between input and output token cost?
Input tokens are the prompt, context, and prior messages sent to the model. Output tokens are generated by the model and are usually priced higher.
When should I use cached input pricing?
Use cached input pricing when your app repeatedly sends the same prompt prefix, system instruction, schema, or context block and the provider applies prompt caching.
How do I estimate monthly GPT cost?
Calculate the average cost per request, then multiply it by expected monthly request volume. For agents, multiply again by the average number of model calls per task.
Is the cheapest GPT model always the best choice?
Not always. A cheaper model can cost more if it requires more retries, longer prompts, or extra validation steps to complete the same job.