Gemini 2.5 Flash Image API: Endpoint & Pricing
Nano Banana (Gemini 2.5 Flash Image) is Google’s high-speed visual generation and editing model designed for low-latency, high‑volume image workflows with strong character and style consistency.
What is Nano Banana (Gemini 2.5 Flash Image)?
Nano Banana (officially Gemini 2.5 Flash Image) is a Google DeepMind model for fast, multimodal text-and-image generation and image editing. It is mainly used for text-to-image creation, conversational image edits, and multi-image fusion scenarios that need low latency and high throughput. It also powers image-centric experiences in the Gemini app and via the Gemini API, Google AI Studio, and Vertex AI for developers and enterprises. It belongs to Google’s Gemini 2.5 family of models and sits alongside successors like Nano Banana Pro (Gemini 3 Pro Image) and Nano Banana 2 (Gemini 3.1 Flash Image).
Can you self-host Nano Banana (Gemini 2.5 Flash Image)?
No. We found no public weights for Nano Banana (Gemini 2.5 Flash Image) on Hugging Face, so there is nothing to download, quantize or serve on your own GPUs: no VRAM budget, no vLLM or GGUF build to plan for. The only way to run it is over an API.
Skip the deploy — use LLM.API as your endpoint
No GPUs, no quantization trade-offs. Same model, OpenAI-compatible, with custom volume discounts on request.
Providers
Different companies host the same model. OpenRouter routes your request to one of them based on the routing mode you pick — Balanced (price + speed), Nitro (fastest), or Exacto (highest tool-calling accuracy).
| Provider | Input | Output | Cache read /M | Latency | Throughput | Uptime |
|---|---|---|---|---|---|---|
| google-ai-studio | — | 33K tokens | vision, tools, streaming | |||
| google-vertex | — | 33K tokens | vision, tools, streaming | |||
| togetherai | — | 33K tokens | vision, tools, streaming |
Prices and availability from the LLMAPI catalogue, updated nightly. Last updated 11 Oct 2026.
Try this model
Test Nano Banana (Gemini 2.5 Flash Image) right here — free to start.
Suggestions for your first prompt
Code snippet
Call the model through the OpenAI-compatible API.
Switching from OpenAI? Change 2 lines.
- base_url="https://api.openai.com/v1"
- api_key="YOUR_OPENAI_KEY"
+ base_url="https://api.llmapi.ai/v1"
+ api_key="YOUR_LLMAPI_KEY"Everything else stays the same — SDK, message format, tools, streaming. Set model to gemini-2.5-flash-image and the call runs unchanged.
curl https://api.llmapi.ai/v1/chat/completions \
-H "Authorization: Bearer $LLMAPI_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "gemini-2.5-flash-image",
"messages": [
{"role": "user", "content": "Give me three crisp launch checklist items."}
]
}'from openai import OpenAI
client = OpenAI(
api_key="YOUR_LLMAPI_KEY",
base_url="https://api.llmapi.ai/v1",
)
resp = client.chat.completions.create(
model="gemini-2.5-flash-image",
messages=[
{"role": "system", "content": "You are a precise product assistant."},
{"role": "user", "content": "Give me three crisp launch checklist items."},
],
)
print(resp.choices[0].message.content)import OpenAI from "openai";
const client = new OpenAI({
apiKey: process.env.LLMAPI_KEY,
baseURL: "https://api.llmapi.ai/v1",
});
const resp = await client.chat.completions.create({
model: "gemini-2.5-flash-image",
messages: [
{ role: "user", content: "Give me three crisp launch checklist items." },
],
});
console.log(resp.choices[0].message.content);stream = client.chat.completions.create(
model="gemini-2.5-flash-image",
messages=[{"role": "user", "content": "Write a haiku about latency."}],
stream=True,
)
for chunk in stream:
delta = chunk.choices[0].delta.content
if delta:
print(delta, end="", flush=True){
"model": "gemini-2.5-flash-image",
"messages": [
{"role": "system", "content": "You are a precise product assistant."},
{"role": "user", "content": "Give me three crisp launch checklist items."}
]
}ENDPOINTS
Supported endpoints & features
Base URL https://api.llmapi.ai/v1 · model ID gemini-2.5-flash-image · OpenAI-compatible.
POST /v1/chat/completionsChat Completions — supported
| Feature | Status | How to set it |
|---|---|---|
| Function calling (tools) | Supported | tools, tool_choice |
| Parallel tool calls | Not supported | parallel_tool_calls |
| JSON mode | Supported | response_format: {"type": "json_object"} |
| Structured outputs | Not supported | response_format: {"type": "json_schema", …} |
| Streaming | Supported | stream: true |
| Vision (image input) | Supported | image_url content parts |
| Web search | Not supported | web_search |
ERRORS
Errors & fallback routing
| Code | What it means | What to do |
|---|---|---|
401 | Missing or invalid API key. | Send Authorization: Bearer YOUR_LLMAPI_KEY and check the key is active. |
429 | Rate limited, or the upstream provider is throttling the request. | Back off and retry with jitter; the gateway also retries the request on another provider where one is available. |
5xx | Upstream provider error or timeout. | Retry; fallback routing sends the retry to the next healthy provider for this model. |
When a provider fails or throttles, the request is routed to the next provider serving this model — the ones listed in the providers table above.
Uptime
Last 30 days
30/30 days operational | 100.00% uptime
Gemini 2.5 Flash Image in production
What the model is good at.
-
Text-To-Image
Generates detailed, high-quality images directly from natural language prompts, leveraging Gemini’s world knowledge for semantically accurate visuals.
-
Image Editing
Performs precise, instruction-based edits on existing images, including targeted region changes, style adjustments, and iterative refinement for production workflows.
-
Multi-Image Fusion
Combines content and styles from multiple reference images into a single coherent output while maintaining visual consistency and scene structure.
-
Character Consistency
Maintains consistent characters, identities, and visual attributes across multiple generated or edited images for storytelling and branding use cases.
-
Multimodal Understanding
Interprets prompts mixing text and images, enabling context-aware generation and edits aligned with both visual references and textual instructions.
What you get when you call Gemini 2.5 Flash Image through LLM.API.
-
Intelligent AI Routing
Automatically route each request to the optimal model across providers based on latency, price, and quality—no client changes required.
One endpoint, any model -
Cost-Aware Optimization
Control spend with policy-driven model selection, rate limits, and real-time cost visibility so teams can experiment freely without budget surprises.
More usage, less spend -
Resilient Fallback Flows
Define provider and model failover chains so requests survive outages, quota limits, and timeouts—with zero logic baked into your app.
Stay online, automatically -
Full-Stack Observability
Trace every call across providers with unified logs, metrics, and latency breakdowns to debug issues and tune performance from one dashboard.
See every token -
Task-Level Orchestration
Express complex workflows as tasks—retrieval, tools, and reasoning—in a single API that abstracts provider quirks and keeps behavior consistent.
Orchestrate, don’t glue-code -
High-Throughput Batch Jobs
Run large-scale generations, evaluations, or data processing as managed batch jobs with automatic chunking, retries, and cost controls.
Scale to millions of calls
When to Use — When NOT to Use
Use it if...
- You need fast, low-cost multimodal inference combining images and short text prompts.
- You need to quickly classify, tag, and filter large volumes of user images.
- Your use case involves generating captions, alt-text, or summaries directly from pictures.
- You need lightweight visual understanding for mobile or web apps with budget constraints.
- Your use case involves prototyping image-based features without requiring top-tier reasoning quality.
- You need to detect simple visual patterns, objects, or layouts rather than nuanced semantics.
Avoid if...
- You need state-of-the-art, deeply accurate visual reasoning on complex or ambiguous images.
- Your workload requires long-context reasoning over many related images and extensive text.
- You need highly reliable domain-expert analysis of medical, legal, or safety-critical imagery.
- Your workload requires consistent, production-critical decisions where small visual errors are unacceptable.
- You need advanced creative image editing or generation beyond simple interpretation and description tasks.
- Your workload requires strict on-prem or fully offline deployment with no external dependencies.
COMMUNITY
What developers say about Nano Banana (Gemini 2.5 Flash Image)
Summarised from public developer discussions and write-ups. Opinions are the sources’, not LLM.API’s.
- Developers on Hugging Face report that the model excels at zero-shot image editing and maintaining character resemblance, though it may fail at specific tasks like clothing extraction compared to open-source alternatives.
- Developers on GitHub highlight the model's production-readiness, noting its high-speed performance, sub-second generation times, and seamless integration using standard HTML image tags or simple API routes.
- Developers on Medium and developer blogs emphasize the model's efficiency in blending multiple images into coherent compositions and its ability to maintain subject consistency across several rounds of editing.
SOURCES
Frequently Asked Questions
-
What is Nano Banana (Gemini 2.5 Flash Image)?
Nano Banana (Gemini 2.5 Flash Image) is a Google multimodal model optimized for fast, low-cost image-plus-text understanding and generation via LLM.API.
-
What modalities does Nano Banana (Gemini 2.5 Flash Image) support?
Nano Banana (Gemini 2.5 Flash Image) supports image inputs combined with text prompts and returns text outputs, making it suitable for many visual understanding workflows.
-
How do I access Nano Banana (Gemini 2.5 Flash Image) through LLM.API?
Call the unified LLM.API completions or chat endpoint with the model identifier for Nano Banana (Gemini 2.5 Flash Image) and your LLM.API key.
-
What is Nano Banana (Gemini 2.5 Flash Image) best suited for?
It is best for fast, inexpensive visual tasks like image captioning, basic OCR, UI understanding, and lightweight vision-language reasoning where latency matters.
-
What is the context window of Nano Banana (Gemini 2.5 Flash Image)?
Nano Banana (Gemini 2.5 Flash Image) supports a context window of up to 32,000 tokens for text, including prompt and response.
-
How fast is Nano Banana (Gemini 2.5 Flash Image) on LLM.API?
Nano Banana (Gemini 2.5 Flash Image) is designed for low latency, typically returning responses significantly faster than larger Gemini vision models at similar workloads.
-
How is Nano Banana (Gemini 2.5 Flash Image) priced on LLM.API?
Pricing is per-token for text and per-image for vision inputs, with Nano Banana positioned as a budget-friendly Gemini vision option on LLM.API.
-
How does Nano Banana (Gemini 2.5 Flash Image) compare to larger Gemini 2.5 vision models?
Compared to larger Gemini 2.5 vision models, Nano Banana trades some reasoning depth and accuracy for much lower cost and faster responses.
-
Does Nano Banana (Gemini 2.5 Flash Image) support streaming responses on LLM.API?
Yes, you can enable streaming on LLM.API to receive Nano Banana (Gemini 2.5 Flash Image) tokens incrementally for lower perceived latency.
-
What are the main limitations of Nano Banana (Gemini 2.5 Flash Image)?
It may struggle with complex multi-step reasoning, very fine-grained visual details, and tasks requiring long, deeply contextualized analysis.
COMPARE
Competitive Models
Qwen Image Edit Plus
— in / — out per image, context varies — the closest current alternative to Gemini 2.5 Flash Image.
CogView-4
— in / — out per image, context varies — the closest current alternative to Gemini 2.5 Flash Image.
GLM-Image
— in / — out per image, context varies — the closest current alternative to Gemini 2.5 Flash Image.
Nano Banana 2 (Gemini 3.1 Flash Image Preview) is Google DeepMind’s image generation and editing model built on the Gemini 3.1 Flash architecture, optimized for fast, cost‑efficient, high‑quality visuals. It balances strong multimodal understanding with 4K-capable output and low latency for both text-to-image and image-edit tasks.
Gemini 3 Flash Preview
Gemini 3 Flash Preview is a Google multimodal large language model optimized for high speed and cost‑effective performance in complex reasoning tasks. It offers long‑context understanding and strong support for agents, coding, and retrieval‑augmented applications.
Nano Banana Pro (Gemini 3 Pro Image Preview)
Nano Banana Pro (Gemini 3 Pro Image Preview) is Google’s preview-stage image generation and editing model built on the Gemini 3 Pro family, optimized for complex, multi-turn visual creation tasks.
Get one key to every model
Swap your API key. Keep your code.