SandBase is live — $1 in free credits on signupStart free ›

Google modelsimage generation api

google/nano-banana

Google's famous original image generation and editing model.

Input
The text prompt to generate an image from.
The aspect ratio of the generated image. Allowed values: 21:9, 16:9, 3:2, 4:3, 5:4, 1:1, 4:5, 3:4, 2:3, 9:16.
The format of the generated image. Allowed values: jpeg, png.
The resolution of the image to generate. Allowed values: 1K, 2K, 4K.
Idle

Example output — click Run to generate your own

API README

Nano Banana

Nano Banana is Google’s compact image creation workflow for turning natural-language direction into polished visual output. This route creates a new image from a prompt, covering photographic, illustrative, product, and graphic-design directions.

The model is especially approachable for conversational iteration: describe the scene or change in ordinary language, review the result, and refine the instruction with concrete details about subject, composition, lighting, style, color, and any text that must appear. Use the supported canvas and resolution controls to prepare the image for its destination.

Highlights

  • Natural-language image creation. Builds complete visual concepts from concise or detailed written briefs.
  • Strong instruction following. Coordinates subject, setting, style, lighting, layout, and requested details across iterative prompts.
  • Visual consistency. Maintains important identity and composition cues while refining or extending a creative direction.
  • Flexible delivery. Offers multiple aspect ratios, resolutions, and common output encodings for production handoff.

Pricing

ConfigurationBilling unitPrice
Base generationPer request$0.04

When to Use

✅ Good fit❌ Consider alternatives
The project needs creating a prompt-led imageThe goal is a different media task or endpoint
The available inputs match the required local schemaRequired source media or permissions are unavailable
The brief can specify subject, composition, style, and deliveryThe result must be deterministic at pixel or sample level
The supported formats and controls match final placementDelivery requires unsupported dimensions, codecs, or duration
An asynchronous generated result fits the workflowA live, frame-synchronous, or real-time response is mandatory

Prompt Guide

Write the request as a production brief: identify the main subject or source material, state the intended transformation, describe composition or timing, and finish with style, atmosphere, and delivery constraints. Keep preservation requirements separate from requested changes, and use only fields exposed by this route.

{
  "prompt": "A high-resolution, studio-lit product photograph of a minimalist ceramic coffee mug in matte black, presented on a polished concrete surface. The lighting is a three-point softbox setup designed to create soft, diffused highlights and eliminate harsh shadows. The camera angle is a slightly elevated 45-degree shot to showcase its clean lines. Ultra-realistic, with sharp focus on the steam rising from the coffee. Square image.",
  "resolution": "1K",
  "aspect_ratio": "21:9",
  "output_format": "jpeg"
}

Technical Specs

SpecValue
Model IDgoogle/nano-banana
Input fieldsprompt (string)<br>resolution (string; 1K, 2K, 4K)<br>aspect_ratio (string; 21:9, 16:9, 3:2, 4:3, 5:4, 1:1, 4:5, 3:4, 2:3, 9:16)<br>output_format (string; jpeg, png)
Required inputprompt
Output fieldsurl, content_type
ExecutionAsynchronous job

Related Models

  • google/nano-banana/edit

Related Models

google/nano-banana/editNano Banana Pro is Google's new state-of-the-art image generation and editing modelgoogle/imagen-3Imagen 3 by Google - generate stunning images from text prompts with state-of-the-art AI. Supports multiple aspect ratios, styles, and high-resolution output for creative and commercial use.google/imagen-3/fastImagen 3 Fast is Google's advanced text-to-image AI model. Create photorealistic images, illustrations, and concept art from natural language descriptions with exceptional detail and prompt adherence.google/imagen-4/previewImagen 4 Preview by Google - generate stunning images from text prompts with state-of-the-art AI. Supports multiple aspect ratios, styles, and high-resolution output for creative and commercial use.google/imagen-4/preview/fastImagen 4 Preview Fast is Google's advanced text-to-image AI model. Create photorealistic images, illustrations, and concept art from natural language descriptions with exceptional detail and prompt adherence.google/imagen-4/preview/ultraImagen 4 Preview Ultra by Google - generate stunning images from text prompts with state-of-the-art AI. Supports multiple aspect ratios, styles, and high-resolution output for creative and commercial use.google/nano-banana-2Nano Banana 2 is Google's new state-of-the-art fast image generation and editing modelgoogle/nano-banana-2-liteNano Banana 2 Lite by Google - generate stunning images from text prompts with state-of-the-art AI. Supports multiple aspect ratios, styles, and high-resolution output for creative and commercial use.