Nano Banana 2
google/nano-banana-2Nano Banana 2 is Google's new state-of-the-art fast image generation and editing model
- Base price
- $0.06USD / run
- Execution
- async
- Model type
- image
- Input fields
- 6
Try the model
Playground
Your output will appear here
Complete the inputs, then click Run.
Specifications
Pricing
- Base price
- $0.06 / run
- Billing formula
- (params.resolution == "0.5K" ? 0.04 : params.resolution == "2K" ? 0.1 : params.resolution == "4K" ? 0.14 : 0.06)
Context & modalities
- Input
- Schema-defined
- Output
- image
Capabilities
- Chat
- Not supported
- Vision
- Not supported
- Reasoning
- Not supported
- Structured output
- Not supported
- Function calling
- Not supported
- Audio input
- Not supported
Access
- Provider
- Model ID
- google/nano-banana-2
- Execution
- async
- API
- Unified Run API
- Endpoint
- /v1/run
API README
Google Nano Banana 2 Text-to-Image
Google's fast image generation model built on Gemini 3.1 Flash architecture. Optimized for speed and cost — delivers quality images with flexible resolutions, extended aspect ratios, and built-in web/image search grounding.
- Need to edit an existing image? Try Nano Banana 2 Edit.
Highlights
Fast generation — Optimized for speed, ideal for high-volume production workflows requiring rapid turnaround.
Web & Image Search grounding — Retrieve web images via Google Image Search as visual background context. Enables reference-aware generation without manually uploading assets.
Extended aspect ratios — Supports extreme ratios like 1:8 and 8:1 for banners, scrolls, and panoramic content, in addition to standard ratios.
Low-cost 0.5K resolution — New 512px output tier at reduced cost for thumbnails, previews, and prototyping.
Free Web & Image Search — Web search and image search grounding included at no extra cost.
Native text rendering — Renders readable text in images across Latin, CJK scripts with correct spelling and placement.
Pricing
| Resolution | Price |
|---|---|
| 0.5K | $0.04 |
| 1K | $0.06 |
| 2K | $0.10 |
| 4K | $0.14 |
| Web Search | Free |
| Image Search | Free |
When to Use
| ✅ Good fit | ❌ Consider alternatives |
|---|---|
| Rapid prototyping and previews | Highest quality brand assets (use Nano Banana Pro) |
| High-volume batch generation | Pixel-perfect text layout |
| Banners and ultra-wide/tall content | Video or animation |
| Thumbnails and social media content | Ultra-high resolution print (4K+) |
| Cost-sensitive workflows | Iterative mask-based editing (use Edit model) |
Prompt Guide
Structure your prompts for best results:
Scene: [environment, time of day, background]
Subject: [main focus, position, action]
Details: [materials, lighting, camera angle, mood]
Text: [exact text to render, font style, placement]
Style: [photorealistic, illustration, flat design, etc.]
Example:
A vibrant 16:9 banner for a music festival. Neon-lit stage with a crowd silhouette in the foreground, confetti in the air. Title text "SUMMER BEATS 2026" in bold graffiti style at center. Electric purple and cyan color palette.
Technical Specs
| Spec | Value |
|---|---|
| Input | Text prompt (max 50,000 characters) |
| Output | PNG or JPEG |
| Resolution | 0.5K / 1K / 2K / 4K |
| Aspect ratio | 21:9, 16:9, 3:2, 4:3, 5:4, 1:1, 4:5, 3:4, 2:3, 9:16, 4:1, 1:4, 8:1, 1:8 |
| Web Search | Google web + image search grounding |
| Reference images | Up to 14 |
| Execution | Async (submit → poll for result) |
| Typical latency | 15–30 seconds |
Related
- Nano Banana 2 Edit — Edit existing images with multi-image reference support
- Nano Banana Pro — Higher quality generation at higher cost
Start building
Send your first request
OpenAI-compatible endpoint with unified 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/v1/run" \
-H "Authorization: Bearer $SANDBASE_API_KEY" \
-H "Content-Type: application/json" \
--data-binary @- <<'SANDBASE_JSON'
{
"model": "google/nano-banana-2",
"prompt": "A photo of a close-up portrait of an elderly Japanese ceramicist with deep, sun-etched wrinkles and a warm, knowing smile. He is carefully inspecting a freshly glazed tea bowl. The setting is his rustic, sun-drenched workshop. The scene is illuminated by soft, golden hour light streaming through a window, highlighting the fine texture of the clay. Captured with an 85mm portrait lens, resulting in a soft, blurred background (bokeh). The overall mood is serene and masterful. Vertical portrait orientation.",
"resolution": "1K",
"aspect_ratio": "1:1",
"output_format": "png",
"enable_web_search": false,
"enable_image_search": false
}
SANDBASE_JSON
)
run_id=$(printf '%s' "$result" | jq -r .id)
for attempt in $(seq 1 120); do
status=$(printf '%s' "$result" | jq -r .status)
case "$status" in completed|failed|timeout) break ;; esac
sleep 2
result=$(curl --fail-with-body --silent \
-H "Authorization: Bearer $SANDBASE_API_KEY" \
"https://api.sandbase.ai/v1/run/$run_id")
done
status=$(printf '%s' "$result" | jq -r .status)
[ "$status" = completed ] || { echo "Generation ended: $status" >&2; exit 1; }
printf '%s\n' "$result"Choose your model
Compare models
| Model | Context | Input / 1M | Output / 1M | Released |
|---|---|---|---|---|
Nano Banana 2This model Google | — | — | — | Feb 26, 2026 |
Google | — | — | — | Jun 30, 2026 |
Google | — | — | — | Jun 30, 2026 |
Google | — | — | — | Jun 30, 2026 |
Google | — | — | — | Feb 26, 2026 |
Google | — | — | — | Nov 20, 2025 |
