Which OpenAI models generate images — and which one you probably want
OpenAI exposes image generation through a single /v1/images/generations endpoint, but the model you pass to it changes everything — price, quality, speed, and which features are available. As of July 2026, there are three actively maintained models worth building against: DALL·E 3, GPT Image 1.5, and GPT Image 1 Mini. (GPT Image 2 launched in April 2026 and supports arbitrary resolutions up to 4K, but is still in limited availability; GPT Image 1 is the original GPT image model and has been superseded by 1.5.)
The short answer: if you’re starting a new project today, use GPT Image 1.5. It’s the best balance of quality and cost for most production workloads. DALL·E 3 is still available but costs more per image and lacks features like transparent backgrounds and streaming that GPT Image models support. GPT Image 1 Mini is the budget option — about 3× cheaper than 1.5 at the same quality tier, with a small quality tradeoff.
Here’s how they compare at a glance:
| Model | Best for | Max native resolution | Transparent backgrounds | Streaming | Per-image cost (med quality, square) |
|---|---|---|---|---|---|
| GPT Image 1.5 | Production apps, high quality | 1536×1024 | Yes | Yes | $0.034 |
| GPT Image 1 Mini | High volume, thumbnails, drafts | 1536×1024 | Yes | Yes | $0.011 |
| DALL·E 3 | Legacy compatibility | 1792×1024 | No | No | $0.040 |
One thing before we get into the code: we run Modellix, an aggregator that offers OpenAI’s image models alongside 210+ others through a single API. We have a commercial interest in this comparison. Every pricing figure here was read from OpenAI’s pricing documentation and image generation guide on July 28, 2026. Where we couldn’t verify something, we say so.
Pricing: what each model actually costs per image
OpenAI bills GPT Image models per token — text input tokens, image input tokens (if editing), and image output tokens. DALL·E models are billed per image. Here’s what you actually pay at standard square resolution (1024×1024):
| Model | Low quality | Medium quality | High quality |
|---|---|---|---|
| GPT Image 1 Mini | $0.005 | $0.011 | $0.036 |
| GPT Image 1.5 | $0.009 | $0.034 | $0.133 |
| GPT Image 1 | $0.011 | $0.042 | $0.167 |
| DALL·E 3 | — | $0.040 (standard) | $0.080 (HD) |
| DALL·E 2 | — | $0.020 | — |
Per-image cost across OpenAI’s image generation models at 1024×1024. GPT Image 1 Mini is the cheapest at every tier; DALL·E 3 only offers standard/HD. Source: OpenAI Pricing, July 2026.
A few things the pricing table doesn’t tell you on its own:
Low quality doesn’t mean bad. On GPT Image 1.5, low quality at $0.009/image produces output that’s perfectly usable for thumbnails, drafts, and rapid prototyping. Medium is where most production apps settle. High is for final assets where every detail matters.
DALL·E 3 gets expensive at larger sizes. A 1792×1024 DALL·E 3 image costs $0.080 at standard quality and $0.120 at HD. GPT Image 1.5 at 1536×1024 medium quality costs $0.050 — less than half the HD price for a near-comparable output.
Image edits cost more. When you use the /v1/images/edits endpoint with GPT Image models, you’re charged for both the input image tokens and the output tokens. A medium-quality edit with one reference image typically adds $0.005–$0.010 to the base generation cost.
Getting your API key and making your first call
Before any code runs, you need an API key and, for GPT Image models, organization verification.
Step 1: Get an API key. Go to platform.openai.com/api-keys, create a new secret key, and copy it. Store it as an environment variable — never hardcode it:
1 | export OPENAI_API_KEY="sk-your-key-here" |
Step 2: Complete organization verification. OpenAI requires API Organization Verification before you can use GPT Image models (gpt-image-1.5, gpt-image-1-mini, gpt-image-1, gpt-image-2). This is separate from adding a billing method — you’ll find it in your developer console. DALL·E models don’t require this step.
Step 3: Install the OpenAI Python SDK:
1 | pip install openai |
That’s it. You’re ready to generate images.
OpenAI exposes image generation through two paths: the Image API (direct /v1/images/ endpoint) and the Responses API (multi-turn editing via GPT-5+ models).
DALL·E 3: the legacy workhorse
DALL·E 3 is the model most developers already know. It uses the same /v1/images/generations endpoint as the GPT Image models but with different parameters and limitations.
1 | from openai import OpenAI |
DALL·E 3 returns a URL (valid for 60 minutes), not base64. You set response_format to "url" or "b64_json". It only supports n=1 — you can’t batch-generate multiple images in one call. The style parameter ("vivid" or "natural") gives you some control over the aesthetic.
The main reasons to use DALL·E 3 in 2026 are legacy compatibility and the revised_prompt field in the response — it shows you how DALL·E reinterpreted your prompt, which can be useful for prompt engineering. For new projects, GPT Image 1.5 does everything DALL·E 3 does, cheaper, with more features.
GPT Image 1.5: the sweet spot for most builds
GPT Image 1.5 is the model you should default to. (For its deprecation timeline and the full trade-off against GPT Image 2, see our gpt-image-1.5 deep dive.) It returns base64-encoded images, supports three quality tiers, transparent backgrounds, JPEG/WebP/PNG output formats, and streaming with partial image previews.
1 | from openai import OpenAI |
Key parameters you’ll use in production:
quality:"low","medium", or"high". Medium is the default and the right starting point. Switch to low for thumbnails and rapid iteration, high for final assets.background:"opaque","transparent", or"auto". Transparent backgrounds are a killer feature for e-commerce and design tools — DALL·E 3 can’t do this. Setoutput_formatto"png"or"webp"when using transparency.output_format:"png"(default),"jpeg", or"webp". Use"jpeg"if latency matters — it’s faster than PNG. Use"webp"for web delivery with smaller file sizes.output_compression: 0–100 for JPEG and WebP. Default is 100 (no compression).
The usage field in the response tells you exactly how many tokens you consumed:
1 | print(f"Input tokens: {response.usage.input_tokens}") |
At $40 per 1M output tokens, a medium-quality 1024×1024 image (1,056 tokens) costs about $0.042 — close to the $0.034 per-image equivalent in OpenAI’s table.
GPT Image 1 Mini: fast and cheap for high volume
GPT Image 1 Mini uses the exact same API and parameters as GPT Image 1.5. The only difference is the model string and the price. At $0.011 for a medium-quality square image, it’s about 3× cheaper than 1.5.
1 | response = client.images.generate( |
Mini is ideal for:
- Thumbnails and previews in content-heavy apps
- A/B testing image variations where cost per variant matters
- Bulk generation pipelines (product photo variants, style transfer at scale)
- Drafts and iterations before switching to 1.5 for the final version
The quality difference between Mini and 1.5 at medium quality is noticeable but not dramatic — Mini handles simple compositions and icons well, and starts to show its limits on detailed photorealism and text rendering.
Editing images and advanced features
The /v1/images/edits endpoint lets you modify existing images with a new prompt. You pass the original image (as a file upload) and a prompt describing what to change:
1 | response = client.images.edit( |
This works with GPT Image models only — DALL·E 2 had an edit endpoint too, but DALL·E 3 doesn’t support editing.
Streaming is available for both the Image API and the Responses API. Set stream=True and partial_images to 1–3 to get progressive previews as the image renders:
1 | stream = client.images.generate( |
Each partial image adds about 100 output tokens to your cost. Partial previews are useful for interactive UIs where users wait for generation — showing intermediate steps keeps them engaged.
The Responses API is an alternative path for multi-turn image workflows. Instead of calling /v1/images/generations directly, you use a mainline model like gpt-5.6 with the image generation tool. This lets you refine images across conversation turns — “make the sky more dramatic,” “now add rain” — without manually passing image bytes between calls. It’s more expensive (you pay for the LLM tokens too) but dramatically simplifies multi-step editing workflows.
One API key for all three — and 210+ more
Every code example above requires you to create an OpenAI account, pass organization verification, manage billing, and handle per-model rate limits. If you’re calling OpenAI’s image models as part of a larger pipeline — maybe you’re also generating video with Kling, running text-to-speech, or comparing outputs across providers — you’re managing multiple API keys, billing relationships, and SDKs.
Modellix is an API aggregator for image and video models. It gives you one API key that works across all three OpenAI image models — DALL·E 3, GPT Image 1.5, and GPT Image 1 Mini — plus 210+ other models from providers like MiniMax, Kling, Seedance, and Stable Diffusion. The API is OpenAI-compatible, so the code you just wrote works with a base URL change:
1 | from openai import OpenAI |
Pricing is per-call with transparent logs — you see the exact cost of each request, not an aggregate bill at the end of the month. No organization verification, no per-model rate limits to negotiate, and the same SDK you already use. If you want the raw endpoint reference — every parameter, response shape, and error code — we have a separate OpenAI image API reference. This guide focuses on integration: which model to pick, what each costs, and working code you can copy.