🎁 New Sign up free, 10 calls on us. Up to $1, no card needed.

gemini-3.1-flash-image-preview Released 2026-05-28

Google image
Input$0.5/M
Output$60/M
Knowledge cutoff2025-01

Provider list prices: no platform markup, pay-as-you-go. These are official list prices. Logged-in customers may see effective prices including workspace discounts on /console/pricing.

Use gemini-3.1-flash-image-preview in 30 seconds

OpenAI-compatible: swap the base_url, keep your SDK. POST /v1/images/generations

from openai import OpenAI

client = OpenAI(
    base_url="https://synthorai.io/v1",
    api_key="sk-syn-...",
)

resp = client.images.generate(
    model="gemini-3.1-flash-image-preview",
    prompt="a watercolor lighthouse at dawn",
    size="1024x1024",
)
print(resp.data[0].b64_json[:80])

About gemini-3.1-flash-image-preview

Expanded resolution from 0.5K to 4K
Extreme aspect ratios like 1:4 and 8:1
Image search grounding blends web results

Gemini 3.1 Flash Image (preview), marketed as Nano Banana 2, delivers high-quality image generation and conversational editing at low latency as the efficient counterpart to Nano Banana Pro.

  • Versus the earlier Nano Banana generation, the official page highlights expanded resolution support (0.5K, 1K, 2K, and 4K), new extreme aspect ratios such as 1:4 and 8:1, Image Search Grounding that blends web text and image results, and improved aspect-ratio adherence, image consistency, and international text rendering.
  • Input tokens reach 131,072 with 32,768 output.
  • Synthorai serves the model over its OpenAI-compatible API surface.

Specs & limits

Max output (vendor spec)32,768
Modalitiestext + image → image + text
Featuresvision · batch · reasoning
Image capabilities0.5K/2K/4K output (default 1K); conversational image editing; extended aspect ratios incl. 1:4, 4:1, 1:8, 8:1; improved i18n text rendering; search grounding supported
NotableGateway preview id has no live official page; GA model code is gemini-3.1-flash-image (released 2026-05-28); caching, function calling, structured outputs not supported.

per Google official docs ↗

FAQ

Is the gemini-3.1-flash-image-preview API free to try?

Yes: new accounts get 10 trial calls and up to $1 in free credit, no card required. That's enough to try gemini-3.1-flash-image-preview against your real workload before adding a payment method.

What is gemini-3.1-flash-image-preview best at?

Expanded resolution from 0.5K to 4K, plus extreme aspect ratios like 1:4 and 8:1 and image search grounding blends web results. See the About section for the full picture from the vendor's own release notes.

How much does gemini-3.1-flash-image-preview cost?

gemini-3.1-flash-image-preview costs $0.5 per million input tokens and $60 per million output tokens on Synthorai. That is the provider's list price, with no platform markup.

How do I generate images with the gemini-3.1-flash-image-preview API?

POST to /v1/images/generations on Synthorai with model="gemini-3.1-flash-image-preview". It follows the OpenAI images API shape, so no vendor SDK is needed.

How do I get access to gemini-3.1-flash-image-preview?

Point your existing OpenAI SDK at base_url="https://synthorai.io/v1", set model="gemini-3.1-flash-image-preview", and you're done. One API key covers every model on the gateway.

Related models

Get your free API key Compare your cost →