GPT Image 2.6 API : AI Images as PNG, WebP, Animated GIF or SVG, at the Exact Size You Need
Try GPT Image 2.6 online right here: write a prompt, pick the file format, then an aspect ratio or an exact size, and get up to 4 images at once, including animated GIFs and SVG vectors. Then call the same model from your product through the GPT Image 2.6 API, with one key and one balance.
- PNG, JPEG, WebP, GIF, SVG
- Exact width × height
- Per image, same price as 2.5
- Open GPT Image 2.6 API
Features
What's New in the GPT Image 2.6 API
Five output formats
Set output_format to png, jpeg, webp, gif or svg and get the file in that format at outputs[].url. Lighter JPEG and WebP for web pages, PNG for editing, an animated GIF or a scalable SVG. The format doesn't change the price.
Animated GIFs
With output_format gif, GPT Image 2.6 draws a looping animation: choose 2 to 64 frames with frame_count and 20 to 2,000 milliseconds per frame with frame_duration_ms, at a frame size you set with size. Good for stickers, reactions, loaders and small product loops.
SVG vector images
With output_format svg you get a vector file that stays sharp at any size, ready for logos, icons and illustrations you can still edit. Display it with an <img> tag, the same way you'd show any image.
Exact width and height
Instead of an aspect ratio, pass size as width x height, for example 1024x768, and the image comes out at exactly that size. The studio offers ready-made sizes for each resolution, so you never pay for a tier larger than the picture.
Transparent backgrounds in more formats
Set background to transparent: PNG and WebP keep a transparent background, a GIF uses a transparent colour and an SVG simply has no background drawn. JPEG has no transparency, so pick another format for cut-outs.
Everything from GPT Image 2.5, same price
Up to 16 reference images named @Image1, @Image2 and so on, five quality levels from low to max, the Flare and Sunburst variants, 1k to 4k and 1 to 4 images per task. The prices are the same as GPT Image 2.5's, per image by quality and resolution.
Overview
What Is GPT Image 2.6?
- Model ID
gpt-image-2.6- Resolution
- 1k / 2k / 4k
- Quality
- Low / Medium / High / X-High / Max
- Formats
- PNG / JPEG / WebP / GIF / SVG
- Aspect ratio
- 15, or an exact size
- Reference images
- Up to 16
- Images per task
- 1–4
- Prompt
- Up to 8000 characters
- Price
- From $0.0117 / image
GPT Image 2.6 is an AI image model that generates pictures from a prompt, optionally guided by reference images, and delivers them in the file format and size you ask for. Alongside the PNG, JPEG and WebP images most apps need, it can draw an animated GIF frame by frame or a vector SVG, which makes it a direct source of stickers, logos, icons and web assets rather than only of pictures that still need converting.
On NanoAPI, GPT Image 2.6 is the model gpt-image-2.6 of the product gpt_image, the same product as GPT Image 2.5, with the same Flare and Sunburst variants at the same price. Every task takes a prompt of up to 8,000 characters and up to 16 reference images, and returns 1 to 4 images. Each result is a file in the chosen format at outputs[].url plus a JPEG preview of up to 1024 pixels on the long side at preview_url; for a GIF the preview is its first frame, and an SVG has no preview, so show the SVG itself with an <img> tag.
Size works two ways. Pass aspect_ratio to get the same sizes as GPT Image 2.5 at 1k, 2k or 4k, or pass size as width x height to get exact dimensions, as long as both sides are multiples of 16 and the picture fits the resolution you pay for. GIF and SVG are made at 1k: a GIF's frames take the size you set, and a vector doesn't need a higher tier.
Use GPT Image 2.6 online in the studio at the top of this page, then call the GPT Image 2.6 API at https://api.nanoapi.ai/v1 from your own app. Both draw on the same prepaid balance at the same price per image, and you only pay for the images you get: an image that isn't generated is refunded, and so is a task that fails.
Pricing
GPT Image 2.6 API Pricing
Priced per image by quality and resolution, the same as GPT Image 2.5: you're charged only for the images a task returns, and output_format, size, frames, variant and background don't change the price.
| Quality | 1k / image | 2k / image | 4k / image |
|---|---|---|---|
Lowlow | $0.0117 | $0.0234 | $0.0351 |
Mediummedium | $0.0234 | $0.0468 | $0.0585 |
Highhigh | $0.0702 | $0.1287 | $0.1989 |
X-Highxhigh | $0.117 | $0.2106 | $0.3276 |
Maxmax | $0.234 | $0.4212 | $0.702 |
Live prices per image. Cost = price per image × number of images; you're only charged for the images you get, and failed runs are fully refunded.
How it works
How to Use the GPT Image 2.6 API
- 1
Step 1: Get your API key
Sign in to NanoAPI with Google and create a key on the API Keys page of the console. It authenticates every GPT Image 2.6 API request, so keep it on your server.
- 2
Step 2: Top up your balance
Add funds on the Top up page of the console. The balance is prepaid in USD, never expires and is shared by every NanoAPI model, so one balance covers images and videos alike.
- 3
Step 3: Create a task
Send POST /v1/tasks with model gpt-image-2.6, a prompt, variant, quality, resolution, output_format, num_outputs and either aspect_ratio or size; a GIF takes size, frame_count and frame_duration_ms instead of aspect_ratio. Add image_urls and background when you need them. The task is queued in under a second.
- 4
Step 4: Get the images
Receive the finished task once at your webhook_url, or poll GET /v1/tasks/{task_id} every 15 seconds or more. A task takes about 30 to 50 seconds from creation; the files are in outputs[].url, with the extension of the format you chose.
Why NanoAPI
Why Use the GPT Image 2.6 API on NanoAPI
One API for images and video
GPT Image 2.6 uses the same POST /v1/tasks endpoint, task object, API key and prepaid balance as every NanoAPI model, so switching from GPT Image 2.5 means changing the model name and adding the new parameters you want.
Unfinished images aren't billed
A task reserves the price of the images you ask for and charges only for the ones it returns. If moderation blocks one of four, the task still succeeds and that image is refunded; if none come back, the whole amount is.
Clear errors before anything is charged
A size that doesn't fit the resolution, a JPEG with a transparent background or an SVG with reference images is rejected at once with 400 invalid_request, the parameter's name and a plain English message. Nothing is created or reserved.
No double charges
Send an Idempotency-Key when you create a task: if a request times out and you resend it, you get the task that was already created instead of a second one.
Spend limits per key
Cap each API key's hourly, daily or total spending in the console, so a bug or a busy day can't use up your balance. Each request is listed with its status, inputs, cost and result.
Try online, then integrate
The studio on this page runs the same GPT Image 2.6 model at the same prices, with the format, size and frame settings linked the way the API expects, so you can settle on them before you write code. The docs also come as one llms.txt file for AI coding assistants.
Use cases
What You Can Build With the GPT Image 2.6 API
Animated stickers and GIFs
Generate reaction stickers, emoji, loading animations and small product loops as GIFs, with the frame count and speed you choose and a transparent colour when they sit on any background.
Logos and icons as SVG
Ask for a flat logo, an icon set or a simple illustration as SVG and drop the vector file into a design, a website or a print layout at any size.
Assets at an exact size
Banners, thumbnails, app screens and social covers come out at the width and height your layout needs, such as 1536x512 or 1280x720, with no cropping step.
Light images for websites and shops
Choose WebP or JPEG for product photos, article images and storefront banners: the files are ready to publish without converting them first. Results are kept for 15 days, so copy them to your own storage.
Transparent cut-outs
Set background to transparent and get PNG or WebP products, characters and stickers ready to place on any background, with reference images to keep a product exact.
Image generation in your product
Add GPT Image 2.6 to a design tool, a marketplace or a content pipeline: let users pick a format and size, create tasks in bulk, get the files by webhook and copy them to your own storage within 15 days.
FAQ
GPT Image 2.6 API FAQ
Can’t find what you need? Write to us.
01What is the GPT Image 2.6 API?
The GPT Image 2.6 API lets your app generate images with the GPT Image 2.6 model over HTTP. On NanoAPI you send POST /v1/tasks with model gpt-image-2.6, a prompt, the output format and the image settings, optionally with up to 16 reference images, and get 1 to 4 images back by webhook or by polling.
02How is GPT Image 2.6 different from GPT Image 2.5?
GPT Image 2.6 adds output_format, so you can get JPEG, WebP, an animated GIF or an SVG as well as PNG, and size, so you can ask for an exact width and height instead of an aspect ratio. Everything else works the same: the prompt and up to 16 reference images, quality from low to max, the Flare and Sunburst variants, 1k to 4k and 1 to 4 images per task, at the same prices.
03How much does the GPT Image 2.6 API cost?
You pay per image: the price of the quality and resolution you choose × the number of images generated, the same as GPT Image 2.5. A task reserves the price of every image in num_outputs, charges only for the images it returns and refunds the rest; a failed task is refunded in full. output_format, size, frame_count, variant and background don't change the price. The live prices are in the table above, on the pricing page and in GET /v1/products.
04How do I make an animated GIF?
Set output_format to gif and resolution to 1k, and pass size (the size of each frame, for example 512x512), frame_count from 2 to 64 and frame_duration_ms from 20 to 2,000. Leave aspect_ratio out: a GIF takes its size from size alone. outputs[].url is the animated GIF; preview_url is only its first frame, so show the url to see it move.
05Can I choose the exact width and height?
Yes. Pass size as width x height with a lowercase x, for example 1024x768, instead of aspect_ratio. Both sides must be multiples of 16 and the long side at most three times the short one; the picture can't have more pixels than the resolution allows, so pick 2k or 4k for larger sizes. A smaller size is still billed at the resolution you chose, which is why the studio lists sizes per resolution.
06Which formats support a transparent background?
Set background to transparent: PNG and WebP come with a transparent background, a GIF uses a transparent colour and an SVG has no background drawn. JPEG can't be transparent, and that combination is rejected with a 400. The JPEG preview at preview_url is placed on white. Asking for transparency only in the prompt paints a checkerboard into an opaque image instead.
07How do I show SVG results safely?
Display the file at outputs[].url with an <img> tag, the same way as any other image, and don't paste the SVG's text into your page. SVG results have no preview_url. If you copy them to your own domain, serve them as downloads with Content-Disposition: attachment. Reference images can't be used with SVG.
08How long does GPT Image 2.6 take, and can I try it first?
About 30 to 50 seconds from creation: a 1k PNG is the fastest, while GIF, SVG and Sunburst with reference images take a little longer. Several images run in parallel, so a task of four takes about as long as one. To try it, sign in with Google and use the studio at the top of this page: same model, same prices and the same balance as the GPT Image 2.6 API.
Start Creating With GPT Image 2.6
Try GPT Image 2.6 in the studio above, then use the GPT Image 2.6 API to bring PNG, WebP, GIF and SVG generation into your product.