Skip to main content

UNLIMITED

Flux 3 Klein, H3 Image, Qwen 2.1, MiniMax H3 Video, 310+ effectsSee plans

WAN 3 prices drop again! 40% off @1080p, 30% @480P, 25% @4K!

All API models

Image generation API

Google Nano Banana 2.1 API

Sharper layouts and subject consistency, with more precise edits.

From$0.063an image

Pay as you go, no subscription.

  • Image to image
  • Editing
A cinematic side-profile portrait of an astronaut standing on a rocky alien beach at sunset, salt spray in the air, twin suns glowing on the horizon, helmet visor catching warm orange light, weathered patches on the spacesuit. Anamorphic lens, soft rim light, sharp focus on the visor.
Made with this API. A cinematic side-profile portrait of an astronaut standing on a rocky alien beach at sunset, salt spray in the air, twin suns glowing on the horizon, helmet visor catching warm orange light, weathered patches on the spacesuit. Anamorphic lens, soft rim light, sharp focus on the visor.

Quickstart

Three steps from zero to a finished file.

  1. 1

    Get a key

    Create an API key. It works for every model on Pixel Dojo.

    Create a key
  2. 2

    Send one request

    POST your input to the endpoint. You get a job ID back right away.

  3. 3

    Collect the result

    Poll the status URL or pass a webhook. The finished file arrives as a link.

  4. Or let your AI coding tool do it

    Copy this prompt into Claude Code, Cursor or Codex. It reads our docs and writes the code.

    Add the Pixel Dojo Google Nano Banana 2.1 API to this project. Read https://pixeldojo.ai/llm/nano-banana-2-1.txt for the endpoint, inputs and prices, and https://pixeldojo.ai/llm.txt for auth, job status and webhooks. Read the key from the PIXELDOJO_API_KEY environment variable. Write one function that submits a job, waits for it to finish and returns the file URL, with errors handled.

POSThttps://pixeldojo.ai/api/v1/models/nano-banana-2-1/run
bash
curl -X POST "https://pixeldojo.ai/api/v1/models/nano-banana-2-1/run" \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "prompt": "a watercolor fox at dawn",
    "resolution": "1K"
  }'

Want the file in one call? Add ?wait=60 to the URL. The request waits for the job and returns the result.

Pricing

You pay per result. Every setting is in the table.

SettingPer image
1K$0.063
2K$0.094
4K$0.188
  • Pay as you go

    Top up from $5. No subscription and no minimum.

  • Failed runs cost nothing

    If a run fails, you get the money back on its own.

  • Know the price first

    Add ?dry_run=true to any request to get its price. Nothing is charged.

Try it

Run a real request and see the exact input and output your code will handle. It is charged like any API call.

Made with this API

Real outputs. Open one to see the request that made it.

Google Nano Banana 2.1 example: A cinematic side-profile portrait of an astronaut standing on a rocky alien beach at sunset, salt spray in the air, t...
See the request

A cinematic side-profile portrait of an astronaut standing on a rocky alien beach at sunset, salt spray in the air, twin suns glowing on the horizon, helmet visor catching warm orange light, weathered patches on the spacesuit. Anamorphic lens, soft rim light, sharp focus on the visor.

14.3s
Google Nano Banana 2.1 example: Wide-angle real estate photograph of a mid-century modern living room, a walnut credenza, a camel leather sofa and a...
See the request

Wide-angle real estate photograph of a mid-century modern living room, a walnut credenza, a camel leather sofa and a round wool rug, floor-to-ceiling windows looking onto a garden, warm afternoon light filling the room. Straight verticals, bright and inviting listing photo.

29.4s
Google Nano Banana 2.1 example: Top-down flat lay of amber glass skincare bottles, a jar of capsules, dried lavender and a smooth river stone on natu...
See the request

Top-down flat lay of amber glass skincare bottles, a jar of capsules, dried lavender and a smooth river stone on natural linen, soft daylight, a calm sage and cream palette with clean negative space. Editorial wellness brand photograph.

13.0s
Google Nano Banana 2.1 example: Aerial photograph of a Mediterranean coastal village, whitewashed houses with blue doors cascading down a cliff to a...
See the request

Aerial photograph of a Mediterranean coastal village, whitewashed houses with blue doors cascading down a cliff to a turquoise harbor, small wooden fishing boats at anchor, golden afternoon light. Travel magazine cover, crisp and saturated.

13.1s
Google Nano Banana 2.1 example: Candid portrait of three co-founders, two women and one man in smart casual clothes, laughing together around a stand...
See the request

Candid portrait of three co-founders, two women and one man in smart casual clothes, laughing together around a standing desk in a startup office with exposed brick and warm wood, big windows letting in soft natural light. Editorial business photography.

13.3s
Google Nano Banana 2.1 example: Studio portrait of a golden retriever sitting upright, head slightly tilted, sharp focused amber eyes with a bright c...
See the request

Studio portrait of a golden retriever sitting upright, head slightly tilted, sharp focused amber eyes with a bright catch light, soft beauty dish lighting on glossy fur, neutral grey backdrop. Professional pet photography, magazine cover quality.

13.0s

Reference

Every input the endpoint takes, and what comes back.

Parameters

Parameter
promptrequiredstringText description of the image to generate
aspect_ratioenum · default 1:1Image aspect ratio1:12:33:23:44:3+5 more
resolutionenum · default 1KOutput resolution tier1K2K4K
reference_imagesarrayHTTPS URLs of one or more reference images for style, composition, or guidance. Multiple images supported.items: urlmax items: 14

What comes back

When you submit (202)

json
{
  "jobId": "job_abc123...",
  "status": "pending",
  "statusUrl": "https://pixeldojo.ai/api/v1/jobs/job_abc123...",
  "priceUsd": 0.0625,
  "creditCost": 1,
  "creditsRemaining": 95,
  "expiresAt": "2026-12-07T18:28:32Z"
}

When it finishes

json
{
  "jobId": "job_abc123...",
  "status": "completed",
  "output": {
    "images": [
      "https://temp.pixeldojo.ai/pixeldojotemp/1705930123-456789.png"
    ]
  },
  "creditCost": 1,
  "expiresAt": "2026-12-07T18:28:32Z"
}

priceUsd is what the run cost, in dollars. expiresAt is when the job record is deleted, 24 hours on. The output links last one hour, so download the file soon.

Use saved characters (@Name)

Write @Name in the prompt to use a character, product, outfit, location, prop or style saved in the account's Character Studio, for example "@Mara on a beach at sunset". Its photos are added to reference_images automatically, after any images you send yourself, so your own image numbering is unchanged. List saved names with GET /api/v1/characters and save new ones with POST /api/v1/characters. An @word that names nothing saved stays plain text.

Aspect ratios

1:1
2:3
3:2
3:4
4:3
4:5
5:4
9:16
16:9
21:9

Other endpoints for this model

Image editing and generation can use different model IDs.

Built for AI agents

Hand these to a coding assistant and it can write the integration for you.

Questions

How much does the Google Nano Banana 2.1 API cost?

From $0.063 an image. The table above has the price for every setting, and each job's response shows what it cost.

Do I need a subscription?

No. Top up from $5 and pay only for what you run.

Can I see the price before I run something?

Yes. Add ?dry_run=true to the request. You get its price back. Nothing is charged and no job starts.

Do I pay for a run that fails?

No. If a run fails, you get the money back on its own.

How long do output links last?

One hour. Download the file in that time, or call the save endpoint to keep it in your library.

Can an AI assistant use this model?

Yes. Connect Claude, ChatGPT or any agent to our MCP server at https://pixeldojo.ai/mcp. Or give it the docs file for this model.

More image APIs

Same key, same request shape. Switch models by changing one word in the URL.

All 84 image APIs

Start building

Try Google Nano Banana 2.1 in the app