OpenAI API Pricing
Updated May 2026 · 12 models
Complete pricing for all OpenAI API models — GPT-5, GPT-5 Mini, GPT-4.1, GPT-4o, o3, and o4-mini. Calculate your monthly cost based on actual token usage.
Compare OpenAI vs Other Providers
Understanding OpenAI API Pricing
OpenAI offers two distinct model families with very different pricing philosophies. The GPT series (GPT-4o, GPT-4.1, GPT-5) is optimized for instruction-following, coding, and structured outputs — pricing is relatively linear with capability. The o-series (o3, o4-mini) adds deliberate chain-of-thought reasoning before responding, making them significantly more expensive but dramatically better at mathematical reasoning, complex coding problems, and multi-step logic.
The GPT-4o vs GPT-5 trade-off. GPT-4o at $2.50/M input tokens remains the workhorse for most production applications — it balances strong capability with predictable pricing. GPT-5, OpenAI's most capable model, commands a premium for tasks where frontier reasoning matters: complex analysis, nuanced writing, advanced coding. For high-volume applications where GPT-4o quality is sufficient, GPT-4o Mini at $0.15/M input tokens provides an 16× cost reduction.
Cached input pricing. OpenAI automatically caches prompt prefixes and offers a 50% discount on repeated context — cached input tokens cost half the standard rate. This is applied automatically for eligible prompts with no code changes required. For applications with static system prompts or repeated document context, you effectively pay 50% less for those tokens on every request after the first. GPT-4o Mini with caching at ~$0.075/M cached input is among the most cost-effective options in the industry.
Batch API for 50% savings. OpenAI's Batch API processes requests asynchronously and returns results within 24 hours at exactly half the standard price. If your use case involves offline document processing, data extraction, content classification, or any non-real-time workload, batch processing is a straightforward way to cut your OpenAI bill in half with no quality trade-off. GPT-4o via Batch API costs $1.25/M input tokens — competitive with smaller models at standard pricing.
Choosing the right model for your workload. Start with GPT-4o Mini for any task that doesn't require frontier-level reasoning — customer support responses, content summarization, simple Q&A, and data extraction. Step up to GPT-4o for tasks that need stronger instruction-following, more coherent long-form output, or better code generation. Reserve o3 or GPT-5 for genuinely hard reasoning tasks where accuracy directly impacts business outcomes. This tiered approach typically reduces overall API spend by 60–80% compared to using a single premium model for everything.