Nano Banana 2 (Gemini 3.1 Flash Image)
google/gemini-3.1-flash-imageNano Banana 2 (Gemini 3.1 Flash Image) is Google's image generation and conversational image editing model in the Gemini 3 series, producing images alongside text from text, image, video and PDF input. Google positions it as the high-efficiency, low-latency counterpart to Nano Banana Pro for high-volume developer use, adding output resolutions from 0.5K to 4K, extra wide and tall aspect ratios, image search grounding and improved multilingual text rendering. Choose Nano Banana Pro for complex, precision design work.
- Input price
- $0.50USD / 1M tokens
- Output price
- $3.00USD / 1M tokens
- Context window
- 131.1K
- Max output
- 32.8K
Try the model
Gemini-native API
This model generates images through the Gemini generateContent API and is not available on Chat Completions or in the Playground. Use the request example below with your SandBase API key.
Model card
Specifications
Pricing
- Input
- $0.50 / 1M tokens
- Output
- $3 / 1M tokens
Context & modalities
- Context window
- 131,072 tokens
- Max output
- 32,768 tokens
- Input
- Text, image
- Output
- Text
Capabilities
- Chat
- Supported
- Vision
- Supported
- Reasoning
- Supported
- Structured output
- Not supported
- Function calling
- Not supported
- Audio input
- Not supported
Access
- Provider
- Model ID
- google/gemini-3.1-flash-image
- Execution
- sync
- Base URL
- https://api.sandbase.ai
- API
- Gemini generateContent API
- Endpoint
- /v1beta/models/google/gemini-3.1-flash-image:generateContent
Start building
Send your first request
Gemini-native endpoint with SandBase API key authentication and usage tracking.
# The quoted heredoc keeps Unicode and shell metacharacters unchanged.
result=$(curl --fail-with-body --silent \
-X POST "https://api.sandbase.ai/v1beta/models/google/gemini-3.1-flash-image:generateContent" \
-H "Authorization: Bearer $SANDBASE_API_KEY" \
-H "Content-Type: application/json" \
--data-binary @- <<'SANDBASE_JSON'
{
"contents": [
{
"role": "user",
"parts": [
{
"text": "A watercolor illustration of a fox in a snowy forest"
}
]
}
],
"generationConfig": {
"responseModalities": [
"TEXT",
"IMAGE"
]
}
}
SANDBASE_JSON
)
printf '%s\n' "$result"Choose your model
Compare models
| Model | Context | Input / 1M | Output / 1M | Released |
|---|---|---|---|---|
Nano Banana 2 (Gemini 3.1 Flash Image)This model Google | 128K | $0.50 | $3.00 | Jun 18, 2026 |
Google | 1M | $4.00 | $20.00 | Oct 13, 2026 |
Google | 64K | $1.50 | $7.50 | Oct 8, 2026 |
Google | 1M | $1.50 | $7.50 | Sep 2, 2026 |
Google | 1M | $1.50 | $7.50 | Aug 13, 2026 |
Google | 1M | $0.30 | $2.50 | Jul 21, 2026 |
Questions
FAQ
How do I call Google Nano Banana 2 (Gemini 3.1 Flash Image) through SandBase?
Create a SandBase API key, then send requests with the model ID "google/gemini-3.1-flash-image" to Gemini generateContent API (/v1beta/models/google/gemini-3.1-flash-image:generateContent) at https://api.sandbase.ai. The request examples on this page show the exact payload.
How much does Google Nano Banana 2 (Gemini 3.1 Flash Image) cost?
$0.50 per 1M input tokens and $3 per 1M output tokens, billed per request from your SandBase balance. Discounts, when available, are shown in the pricing on this page.
What is the context window of Google Nano Banana 2 (Gemini 3.1 Flash Image)?
131.1K tokens of context, with up to 32.8K output tokens per response.
Which features does Google Nano Banana 2 (Gemini 3.1 Flash Image) support?
Google Nano Banana 2 (Gemini 3.1 Flash Image) supports vision (image input), reasoning. See Specifications above for the full list.
Do I need a separate Google account?
No. One SandBase API key and balance gives you access to Google Nano Banana 2 (Gemini 3.1 Flash Image) and the other models in the catalog; you do not need to sign up with Google separately.
