GPT Image vs Nano Banana: cost per image and when to use which
Nano Banana 2.1 costs about $0.034 per image while GPT-5.4 Image 2 costs about $0.04. Compare pricing, text rendering, and image editing features.
On this page 7 sections
Nano Banana 2.1 costs about $0.034 per image, GPT-5.4 Image 2 costs about $0.04 per image, and Nano Banana 2 costs about $0.067 per image. If your application needs crisp typography rendered directly inside an image or relies on complex, paragraph-length prompts, GPT Image (vibiz/image-text) is the right fit. If you need lower per-generation costs, fast turnarounds, multi-image edits, or consistent characters across scenes, Nano Banana (vibiz/image-pro or vibiz/image) is the better option.
Both families are accessible through the AI gateway on thelastapi with a single API key, using standard OpenAI SDK image methods or curl.
What is the cost per image across models?
Image generation APIs charge per image generated rather than per token. On thelastapi, each image model runs the exact lab model behind a stable alias. Every JSON API response contains cost_micro_usd so you can record the exact microdollar cost of every generation alongside the prompt and user ID.
| thelastapi model | Runs on | Best suited for | Price (USD) |
|---|---|---|---|
vibiz/image-pro | Nano Banana 2.1 (Google) | Fast generation, low cost, character consistency | about $0.034 per image |
vibiz/image-text | GPT-5.4 Image 2 (OpenAI) | Legible text rendering, long descriptive prompts | about $0.04 per image |
vibiz/image | Nano Banana 2 (Google) | Reliable image-to-image edits, character consistency | about $0.067 per image |
At 10,000 images per month:
- Nano Banana 2.1 (
vibiz/image-pro) costs about $340. - GPT-5.4 Image 2 (
vibiz/image-text) costs about $400. - Nano Banana 2 (
vibiz/image) costs about $670.
If you generate tens of thousands of graphics each month—such as dynamic social post backgrounds, blog thumbnails, or user avatars—choosing vibiz/image-pro saves meaningful budget over time. If your workflow requires precise product labels, greeting cards, or signage where garbled letters ruin the asset, vibiz/image-text avoids wasted reruns.
You can also read more about accessing these models under a single account in our guide on an image generation API for developers.
When should you choose GPT Image?
GPT Image, available as vibiz/image-text (running GPT-5.4 Image 2), is designed for prompts where semantic precision and typography matter most.
In-image typography
Most image generation models struggle with text: words come out misspelled, letters blur together, or characters morph into decorative squiggles. GPT-5.4 Image 2 handles legible, accurately spelled text placed inside the generated picture. Use it for:
- Marketing graphics, social media banners, and book covers.
- UI mockups containing headlines and button text.
- Badges, event tickets, stickers, and t-shirt graphics.
- Street signs, shopfront storefronts, and restaurant menus.
Long, complex prompt following
When a prompt contains detailed compositional requirements—specifying the foreground, midground, lighting angle, color palette, and multiple distinct objects—GPT Image follows instructions closely without dropping secondary clauses. If your application constructs prompts programmatically by combining multiple user preferences, GPT Image preserves those fine-grained requirements reliably.
When should you choose Nano Banana?
Nano Banana, available as vibiz/image (Nano Banana 2) and vibiz/image-pro (Nano Banana 2.1), excels at high-volume generation, character consistency, and photo editing.
Lower production cost
At about $0.034 per image, vibiz/image-pro is the lowest-priced image tier on the platform. It cuts generation spend by roughly 15 percent compared to GPT Image and nearly 50 percent compared to Nano Banana 2. For background generation, game asset prototyping, or consumer-facing apps where users generate multiple variations, vibiz/image-pro provides high visual fidelity at scale.
Multi-image consistency and photo editing
Nano Banana models accept existing image URLs to guide the generation process. By supplying source photos, you can preserve subject likeness, facial features, or artistic styling across multiple generated outputs. For setup steps specific to Google's architecture, review our walkthrough on how to use Nano Banana with an API key.
Bringing your own Google credentials
If you have Google Cloud credits or prefer to pay Google directly, you can link your own Gemini API key:
GEMINI_API_KEY=your_key_here vibiz ai keys set googleWhen configured, calls to Google models (vibiz/image, vibiz/image-pro, and any google/… model) run directly against your Google account and cost $0 on thelastapi. The API response marks the request as "paid_by": "your_key" and lists would_cost_micro_usd to show what the call would have cost normally. Calls to OpenAI models like vibiz/image-text continue running on thelastapi as usual.
How to edit existing photos with image inputs
Both model families allow you to edit photos or build variations by passing image URLs alongside your text prompt. You can supply image_url for a single reference image, or image_urls with up to 8 links to combine elements (such as placing a specific person into a specific clothing item or background).
If you submit an image URL to a model that does not accept photo inputs, the gateway returns a 400 invalid_request error with details.reason: "model_takes_no_photo" instead of silently ignoring the reference.
From the command line, use the vibiz CLI:
vibiz image "change the background to a sunny beach" \
--model vibiz/image \
--from-image https://thelastapi.dev/f/prj_123/profile.png \
-o beach-portrait.pngCalling both models through one OpenAI client
Because the AI gateway uses an OpenAI-compatible format, switching between GPT Image and Nano Banana requires only changing the model parameter. You do not need multiple SDKs or vendor-specific request adapters.
To configure your project environment:
vibiz devThis exports VIBIZ_AI_BASE_URL and VIBIZ_AI_API_KEY into your local environment. You can then use the standard OpenAI client:
import OpenAI from 'openai';
const openai = new OpenAI({
baseURL: process.env.VIBIZ_AI_BASE_URL,
apiKey: process.env.VIBIZ_AI_API_KEY,
});
// 1. Generate a marketing banner with text using GPT Image
const gptImage = await openai.images.generate({
model: 'vibiz/image-text',
prompt: 'A sleek coffee shop window with a gold painted sign that reads "Morning Roast"',
response_format: 'url',
});
console.log('GPT Image link:', gptImage.data[0].url);
// 2. Generate a character portrait using Nano Banana 2.1
const bananaImage = await openai.images.generate({
model: 'vibiz/image-pro',
prompt: 'A watercolor portrait of an astronaut sitting in a field of poppies',
response_format: 'url',
});
console.log('Nano Banana link:', bananaImage.data[0].url);You can also send requests over plain HTTP using curl:
curl https://thelastapi.dev/v1/ai/images/generations \
-H "Authorization: Bearer $VIBIZ_AI_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "vibiz/image-pro",
"prompt": "An isometric 3D render of a cozy developer workspace",
"response_format": "url"
}'For applications that also produce audio, speech, or video alongside still images, see our overview of one API for image, video and voice AI models.
How generated images are saved and linked
Every time you generate an image within a project, the resulting asset is saved automatically to the project's Files storage.
Unlike standard third-party URLs that expire within an hour, requests passing response_format: "url" within a project return permanent public links hosted at https://thelastapi.dev/f/<key>/<name>. The response payload includes:
{
"created": 1730112000,
"data": [
{
"url": "https://thelastapi.dev/f/Qm9x123abc/2026-10-28-cozy-workspace.png",
"file_id": "file_01k123abc",
"file_url": "https://thelastapi.dev/f/Qm9x123abc/2026-10-28-cozy-workspace.png"
}
]
}Files are cataloged with the prompt, the model used, the timestamp, and the generation cost. You can look up generated files at any point via the CLI:
# Get the URL of the most recently generated image
vibiz files latest --type image
# Search your generated images by prompt text
vibiz files search "coffee shop window"Calls made using account keys without an associated project do not write to Files storage, and their asset links expire after 24 hours.
To start testing both models, check the model directory with vibiz ai models or review the full specifications in the AI documentation.
Frequently asked questions
Can I edit an image by uploading a local file directly in the API request?
The `image_url` and `image_urls` parameters require public HTTPS links; you can upload your local file using `vibiz files upload photo.png` or `POST /v1/projects/:id/files` to get a permanent link first, then pass that URL into the generation request.
How do image generation size limits compare between Nano Banana and GPT Image?
Requests support dimensions between 256 and 2,048 pixels per side across both models, with up to 4 images requested in a single generation call.
What happens if Nano Banana or GPT Image is temporarily unavailable?
The request fails with a `503 model_unavailable` or `503 provider_unavailable` error including a retry hint; the API will never quietly substitute a different model behind your back.