OpenAI API Pricing in 2026: Per-Token Costs for GPT-5, GPT-4o, DALL-E, Sora and Whisper
OpenAI API pricing in 2026 is billed per token and is completely separate from ChatGPT subscriptions. GPT-5 costs about 1.25 dollars per 1M input tokens and 10 dollars per 1M output tokens. GPT-5 mini drops to 0.25 dollars input and 2 dollars output per 1M. GPT-5 nano is 0.05 dollars input and 0.40 dollars output. The Batch API gives a 50 percent discount with a 24 hour turnaround, prompt caching auto-applies a 50 percent discount on cached input tokens, and new accounts get 5 to 18 dollars in starter credits. This is developer pricing, not a consumer plan. Verified May 2026.
GPTPrompts.AI Editorial
GPT Prompts editorial team. Pricing verified against official OpenAI API pricing pages. Β· Last updated May 23, 2026
Before you pay full price for OpenAI API, check for a deal
AIDeals.app tracks verified discounts on the AI tools you already want, annual-billing savings, student and nonprofit programs, free tiers, and promo codes, every deal checked by hand and stamped with its verification date. Plus free AI cost calculators to plan your stack.
AIDeals.app is our sister site for verified AI-tool discounts.
Important: this is developer pricing
The OpenAI API is billed completely separately from ChatGPT subscriptions. If you are an end user looking for a chat window in your browser, you want the ChatGPT pricing page, not this one. The API is for developers building apps that call OpenAI models programmatically. Per-token pricing applies. There is no monthly subscription, no flat fee, and no overlap with your ChatGPT Plus or Pro plan. Verified May 2026.
How we verify OpenAI API pricing
Every price on this page is checked against the official OpenAI API pricing page (openai.com/api/pricing) and the relevant model documentation. We re-verify quarterly and after any model launch or price cut. If a price changes, we update the table, the FAQ, and the AI Visibility block, then advance the verification date. We do not estimate or project pricing. All prices verified May 2026.
Every OpenAI API model and its price
The full OpenAI API lineup, what each model is for, and what you pay per token, per image, per second, or per minute. Pricing verified May 23, 2026.
| Model | Price | Best for | What you get |
|---|---|---|---|
| GPT-5 | 1.25 dollars input / 10 dollars outputper 1M tokens | Production agents, reasoning, and complex generation | Flagship reasoning and generation model. Highest capability, largest context window in the GPT-5 family, and the right default when accuracy matters more than per-call cost. Cached input runs at half the input price. |
| GPT-5 mini | 0.25 dollars input / 2 dollars outputper 1M tokens | High-volume product features and most chatbot calls | A fifth the input price of GPT-5 and a fifth the output price. Strong general-purpose model that handles the bulk of production workloads at a fraction of the flagship cost. Pairs well with prompt caching. |
| GPT-5 nano | 0.05 dollars input / 0.40 dollars outputper 1M tokens | Classification, routing, extraction, and ultra-cheap calls | The cheapest text model in the lineup. Built for narrow tasks at massive scale: intent routing, content moderation, tag extraction, simple summaries. Twenty-five times cheaper than GPT-5 on input. |
| GPT-4.1 | 2 dollars input / 8 dollars outputper 1M tokens | Apps still on GPT-4.1 contracts and long context windows | The previous flagship, kept available for production apps that already validated against it. Lower input price than GPT-4o, comparable output, and a generous context window. Still a reasonable default for legacy code. |
| GPT-4o | 2.50 dollars input / 10 dollars outputper 1M tokens | Multimodal apps mixing text, vision, and audio | The omni model that brought native vision and audio together. Still the right pick if your app sends images or audio to the same endpoint as text. Slightly more expensive than GPT-4.1 on input. |
| o1-mini | Reasoning model, mid-tier pricingper 1M tokens | Reasoning tasks where GPT-5 is overkill | A smaller reasoning model. Slower than the GPT family because it thinks before it answers, but the per-task cost can be lower than GPT-5 on problems where you would otherwise burn output tokens iterating. |
| DALL-E 3 | 0.04 dollars / 0.08 dollarsper image (standard / HD) | Programmatic image generation | Image generation priced per call, not per token. Standard quality at roughly 0.04 dollars, HD at roughly 0.08 dollars. Useful as a benchmark when comparing image generation to chat completions on cost. |
| Sora 2 | Per second of videobilled by output duration | Programmatic short-form video generation | Sora 2 video generation is billed per second of output video, with the per-second rate varying by resolution and tier. Far more expensive per call than text models. Plan budgets around seconds, not tokens. |
| Whisper | 0.006 dollarsper minute of audio | Transcription, voice notes, meeting capture | Audio transcription at six tenths of a cent per minute. The cheapest workhorse in the entire API. A 60 minute call transcribes for about 0.36 dollars, which makes voice features economically viable in almost any product. |
| TTS | About 15 dollarsper 1M characters | Voice output, narration, and accessibility | Text to speech priced per character. About 15 dollars per million characters generated. Pairs naturally with Whisper for a full speech-in, speech-out loop without leaving the OpenAI API surface. |
| text-embedding-3-small | 0.02 dollarsper 1M tokens | Search, RAG, semantic similarity at scale | Embedding pricing is roughly two orders of magnitude cheaper than chat output. Embedding an entire 1M token corpus costs about two cents. The right pick for RAG systems that re-embed regularly. |
GPT-5 vs GPT-5 mini vs GPT-5 nano
The three GPT-5 family models head to head. This is the matrix most developers are actually deciding between when picking a default model for production traffic.
| Dimension | GPT-5 | GPT-5 mini | GPT-5 nano |
|---|---|---|---|
| Input price per 1M tokens | 1.25 dollars | 0.25 dollars | 0.05 dollars |
| Output price per 1M tokens | 10 dollars | 2 dollars | 0.40 dollars |
| Best for | Reasoning, hard tasks | Most app traffic | Routing, classification |
| Cached input discount | 50 percent off | 50 percent off | 50 percent off |
| Batch API discount | 50 percent off | 50 percent off | 50 percent off |
| Context window | Largest in family | Large | Smaller but workable |
| Latency | Standard | Faster | Fastest |
| Typical use | Agents, reasoning | Chatbots, summaries | Tag extraction |
| Realtime price vs Batch | 2x Batch | 2x Batch | 2x Batch |
GPT-5 on the API: when the flagship is worth 5x the price
GPT-5 at about 1.25 dollars per 1M input tokens and 10 dollars per 1M output tokens is the most capable model in the OpenAI API as of May 2026. The instinct for many developers is to make GPT-5 the default. In practice, that burns money on every routine call. The right move is to default to GPT-5 mini for most traffic and reserve GPT-5 for calls where the task is hard enough that mini misses. In our stack, only about 20 percent of calls route to GPT-5 directly, and another 10 percent are escalations from a mini call that failed a quality check. The rest stay on mini or nano.
GPT-5 mini at 0.25 dollars per 1M input: the real production workhorse
GPT-5 mini at 0.25 dollars per 1M input tokens and 2 dollars per 1M output tokens is the model most chatbots, copilots, and content tools should be running on. It is 5x cheaper than GPT-5 on input and 5x cheaper on output. Quality is close enough on routine work that most users cannot tell the difference. Pair it with prompt caching for a stable system prompt and you are paying half the input rate on most calls. Pair it with the Batch API for any non-realtime work and you are paying half again. Stacking those discounts moves the effective input cost into the cents-per-million range.
GPT-5 nano at 0.05 dollars per 1M input: when you only need a routing decision
GPT-5 nano at 0.05 dollars per 1M input tokens and 0.40 dollars per 1M output tokens is built for high-volume narrow tasks. Classification, intent routing, tag extraction, content moderation, simple summaries. At this price you can embed an LLM call in places where the unit economics would not have made sense at flagship pricing. A million classification calls on nano cost about 50 dollars total assuming short prompts. The same workload on GPT-5 is roughly 25 times more expensive.
GPT-4.1 and GPT-4o on the API: still relevant in 2026
GPT-4.1 at 2 dollars per 1M input and 8 dollars per 1M output is the prior flagship. Apps that validated their prompts and evals against GPT-4.1 often keep running on it because re-validation costs engineering time. GPT-4o at 2.50 dollars per 1M input and 10 dollars per 1M output is still the right answer when your app sends mixed text, image, and audio inputs to a single endpoint. Neither is a default pick for new builds in 2026. New apps should start on GPT-5 mini and selectively upgrade to GPT-5 where needed.
DALL-E 3, Sora 2, Whisper, and TTS: pricing in the multimodal lineup
Image, video, and audio models price differently from text. DALL-E 3 is about 0.04 dollars per standard image and 0.08 dollars per HD image. Sora 2 video is billed per second of output, with the per-second rate varying by resolution. A 10 second high-resolution clip can cost more than a hundred DALL-E images, so budget control for video features should track seconds generated, not raw API calls. Whisper at 0.006 dollars per minute of audio is the cheapest workhorse in the entire API: a 60 minute call transcribes for about 0.36 dollars. TTS at about 15 dollars per 1M characters lets you build a full speech-in, speech-out loop on OpenAI infrastructure.
Embeddings and the cost of running RAG at scale
The text-embedding-3-small model at 0.02 dollars per 1M tokens is roughly two orders of magnitude cheaper than chat output. Embedding an entire 1M token corpus costs about two cents. That is what makes RAG economically viable at scale: you can re-embed your knowledge base on a regular cadence without making a meaningful dent in your monthly bill. The larger and higher-dimensional embedding models cost more but follow the same pricing pattern. Plan your RAG budget around inference (chat completion) cost, not embedding cost.
Batch API vs realtime: a 50 percent discount for 24 hours of patience
The Batch API gives a flat 50 percent discount on both input and output tokens compared to realtime endpoints. The trade is processing time: jobs complete within a 24 hour window instead of in real time. Submit a JSONL file of requests, poll for completion, get the results back. Use cases that fit perfectly: nightly classification of yesterdays content, bulk summarization of a document backlog, weekly report generation, monthly embedding refreshes of a large corpus. The Batch API is one of the biggest cost levers most teams underuse. Walking through your workload and tagging anything that does not need to be realtime is usually a quick path to cutting the bill by 20 to 40 percent.
Prompt caching: the discount you get without writing any code
Prompt caching automatically detects when a long prefix of your prompt is the same as a recent call (within a 5 to 10 minute window) and bills that cached portion at 50 percent of the normal input rate. There is no API flag to enable, no code change required. It is auto-applied. The savings are largest when you have a long, fixed system prompt with variable user input appended at the end. To maximize it: put stable content first (system prompt, retrieved documents, examples) and variable content last (user message, current question). Many production chatbots see 30 to 60 percent reduction in input token cost from prompt caching alone.
Cached input savings math, worked out
Take a chatbot that sends a 3,000 token system prompt plus 200 tokens of user input per call on GPT-5 mini. Input cost without caching: 3,200 tokens times 0.25 dollars per 1M = 0.0008 dollars per call. With caching applied to the 3,000 token system prompt, the cached portion is billed at 0.125 dollars per 1M while the new 200 tokens are billed at the full 0.25 dollars per 1M. New per-call input cost: about 0.000425 dollars. That is a 47 percent reduction in input cost, achieved with zero code changes, just by keeping the system prompt stable across calls. At a million calls per month, that is roughly 375 dollars in input cost saved per month on just one model.
When self-hosting beats the API
Self-hosting open-weight models like Llama 4 or Qwen on your own GPUs only beats the OpenAI API at very specific scale and use-case profiles. The break-even is roughly: sustained traffic above 50 million output tokens per day with steady utilization, a narrow workload that a smaller open model handles well, and an engineering team that already owns the infra muscle. For everything below that bar, the OpenAI API is cheaper after factoring in GPU rental, ops staff time, model evaluation, and the lost capability of GPT-5. Most teams should stay on the API until they have both the volume and the workload pattern that makes self-hosting pay back. Verified May 2026.
What we actually pay for in our own stack
Across our own production stack, the routing mix is roughly 70 percent GPT-5 mini, 15 percent GPT-5 nano (for classification and routing layers), 10 percent GPT-5 (for the hardest reasoning calls), and 5 percent everything else (embeddings, Whisper, TTS, DALL-E). Prompt caching is auto-applied across all chat models. The Batch API handles our nightly summarization and weekly report generation. The combined effect is that our average effective input cost sits around 0.10 dollars per 1M tokens, well below the headline GPT-5 mini rate of 0.25 dollars. That is the kind of number you should be targeting once you have the discount stacking dialed in.
The verdict: which OpenAI API model should you pick
My verdict after building on this API for years: default new builds to GPT-5 mini, route classification and intent calls to GPT-5 nano, and reserve GPT-5 for the hardest reasoning. Always turn on prompt caching by structuring your prompts correctly, and route everything that does not need a realtime response through the Batch API for the 50 percent discount. Start on the starter credit, hit Tier 1 after spending 5 dollars, and let the tier ladder lift you naturally as production traffic accumulates. The single biggest mistake I see new developers make is calling GPT-5 by default for everything. The single biggest cost win is moving to mini and stacking the caching and batch discounts. Verified May 2026.
OpenAI API pricing FAQ
How much does the OpenAI API cost compared to a ChatGPT subscription?
The OpenAI API and ChatGPT are billed completely separately. ChatGPT Plus is a flat 20 dollars per month for human use in a chat window. The API is pay-as-you-go per token for developers building apps. GPT-5 on the API is about 1.25 dollars per 1M input tokens and 10 dollars per 1M output tokens. A typical chatbot conversation uses a few thousand tokens, so the per-call cost is tiny, but heavy app traffic can quickly exceed a 20 dollar monthly subscription. Verified May 2026.
What is the price difference between GPT-5 and GPT-5 mini on the API?
GPT-5 is about 1.25 dollars per 1M input tokens and 10 dollars per 1M output tokens. GPT-5 mini is about 0.25 dollars input and 2 dollars output per 1M tokens. That is a 5x cheaper input and 5x cheaper output. For most production traffic, GPT-5 mini is the right default and you reserve GPT-5 for the hardest reasoning calls. We route roughly 80 percent of traffic to mini in our own stack and only escalate to GPT-5 when mini fails a quality check. Verified May 2026.
How does the OpenAI Batch API discount work?
The Batch API gives a 50 percent discount on both input and output tokens compared to realtime endpoints. The trade is processing time: batch jobs complete within a 24 hour window instead of in real time. Submit a JSONL file of requests, get the results back asynchronously. Use cases that fit this model include nightly content classification, bulk summarization, weekly report generation, and embedding refreshes. If your workload does not need a realtime response, the Batch API cuts your bill in half with no quality difference. Verified May 2026.
What is prompt caching and how much does it save?
Prompt caching automatically detects when a long prefix of your prompt is the same as a recent call (within a 5 to 10 minute window) and bills the cached portion at 50 percent of the normal input rate. It is auto-applied with no code changes required. The savings are largest when you have a long, fixed system prompt with retrieved context appended at the end. Many production apps see 30 to 60 percent input token bill reduction just from this. The implementation detail is to put stable content first and variable content last. Verified May 2026.
Are there free credits when you sign up for the OpenAI API?
Yes. New OpenAI API accounts get a starter credit of 5 to 18 dollars depending on region and promotion at sign up. The credit expires after 3 months and only applies to API usage, not ChatGPT. That is enough to fully explore the API, build a working prototype, and ship a small private project. For serious building you will move to pay-as-you-go billing quickly because real product traffic exceeds the starter credit within days. Verified May 2026.
What are the OpenAI API rate limits by tier?
OpenAI uses a usage tier system from Tier 1 to Tier 5, gated by total spend and account age. Tier 1 starts at low requests per minute and tokens per minute caps suitable for development. Higher tiers unlock progressively more headroom. Tier 5 supports very high throughput and is typically required for production-scale apps. Hitting your tier cap returns a 429 response. You upgrade tiers automatically by spending the required threshold and waiting the minimum account age. Verified May 2026.
How does OpenAI image generation pricing compare to video?
DALL-E 3 is billed per image: about 0.04 dollars per standard 1024x1024 image and about 0.08 dollars for HD. Sora 2 is billed per second of generated video, with the per-second rate varying by resolution and tier. A 10 second clip at high resolution can cost more than 100 standard DALL-E 3 images. The implication for product budgets is to treat images as nearly free and video as a premium feature with explicit per-generation cost monitoring. Verified May 2026.
How does OpenAI API pricing compare to the Anthropic API?
At the flagship tier both APIs price in a similar range. GPT-5 is about 1.25 dollars per 1M input and 10 dollars per 1M output. Claude 4.5 Sonnet is about 3 dollars per 1M input and 15 dollars per 1M output. So GPT-5 is cheaper on input and on output at the flagship level. At the mini and nano tiers OpenAI is meaningfully cheaper than Claude Haiku on input. Anthropic prompt caching can be more aggressive in discount depth, but both providers now offer caching, batching, and cached input discounts. Verified May 2026.
What does a typical monthly OpenAI API bill look like for a small app?
A small SaaS app with 1,000 daily active users and 5 chat exchanges per user, each exchange using 1,500 input and 800 output tokens on GPT-5 mini, runs roughly: 30 days x 1,000 users x 5 calls x 1,500 input = 225M input tokens at 0.25 dollars per 1M = 56 dollars. Output: 30 x 1,000 x 5 x 800 = 120M tokens at 2 dollars per 1M = 240 dollars. Total around 296 dollars per month before any caching or batch discount. With prompt caching at 50 percent on a long system prompt and Batch API for any non-realtime work, real bills come in 30 to 50 percent lower. Verified May 2026.
How do I upgrade from Tier 1 to Tier 5 on the OpenAI API?
Tier upgrades are automatic once you meet two conditions: minimum cumulative spend on the account and minimum account age in days. Tier 1 starts at 5 dollars spent. Tier 2 typically requires 50 dollars spent and 7 days. Tier 3 requires 100 dollars and 7 days. Tier 4 requires 250 dollars and 14 days. Tier 5 requires 1,000 dollars and 30 days. There is no manual application process. The fastest path to Tier 5 is consistent production traffic, not a one-time large prepayment, because the day count is also required. Verified May 2026.
Can I get a refund on unused OpenAI API credits?
OpenAI does not generally refund prepaid API credits once they are added to your balance. Auto-recharge top-ups are non-refundable. If you accidentally over-prepaid or made a duplicate top-up, contact OpenAI support through the help center within a reasonable window and explain the situation. Free starter credits granted at sign up are never refundable in cash and expire after 3 months. For enterprise contracts, refund terms are whatever was negotiated in the master agreement. Verified May 2026.
Has OpenAI API pricing changed recently?
OpenAI has cut prices consistently year over year since 2023. GPT-4o launched at half the price of GPT-4 Turbo. GPT-5 launched at meaningfully lower per-token prices than the GPT-4.1 generation while improving capability. GPT-5 nano introduced a new floor for cheap text generation at 0.05 dollars per 1M input tokens. The Batch API discount and prompt caching are both relatively recent additions that compound the savings. We re-verify every price on this page against the official OpenAI pricing page on a regular cadence. Last verified May 23, 2026.
Related pricing and comparison guides
Consumer ChatGPT plans from Free to Enterprise
Full Claude consumer and API pricing breakdown
Google AI Pro, Ultra, and Gemini API costs
Every major LLM API and consumer plan compared
Cursor plans and how API costs flow through
Head to head AI tool comparisons across the market
Keep reading
Related guides you'll like
- Prompt Engineering
ChatGPT API Prompting
Prompting strategies for the OpenAI API
Read guide β - AI Model Prompts
ChatGPT Prompts
Master ChatGPT with advanced prompting techniques, mega-prompts, and proven frameworks
Read guide β - AI Tools & Apps
OpenAI Codex Prompts
Prompts for OpenAI Codex CLI coding agent for code generation, debugging, and multi-file projects
Read guide β - Image & Video Generation
Sora Prompts
AI video generation prompts for OpenAI Sora cinematic scenes, product videos, and creative content
Read guide β - Image & Video Generation
DALL-E 3 Prompts
Create stunning images with DALL-E 3 prompt strategies
Read guide β - AI Tools & Apps
ChatGPT Search Optimization
Make pages more useful for ChatGPT Search users with answer-first structure, sources, and task-ready next steps
Read guide β