---
title: Google: Nano Banana 2 (Gemini 3.1 Flash Image) | Text Generation | ModelsLab
description: Build with Google: Nano Banana 2 (Gemini 3.1 Flash Image) API by Google. Text generation, chat, code, and reasoning. Pay-per-use. Free tier.
url: https://modelslab-frontend-v2-927501783998.us-east4.run.app/models/google/google-gemini-3.1-flash-image.md
canonical: https://modelslab-frontend-v2-927501783998.us-east4.run.app/models/google/google-gemini-3.1-flash-image.md
type: product
component: Playground/LLM/Index
generated_at: 2026-06-30T00:03:29.206536Z
---

Google: Nano Banana 2 (Gemini 3.1 Flash Image)
---

 [LLMs.txt](https://modelslab-frontend-v2-927501783998.us-east4.run.app/models/open_router/google-gemini-3.1-flash-image/llms.txt) [.md](https://modelslab-frontend-v2-927501783998.us-east4.run.app/models/google/google-gemini-3.1-flash-image.md)

Google: Nano Banana 2 (Gemini 3.1 Flash Image)
---

Choose a prompt below to get started or type your own message

 Explain quantum computing in simple terms

 Write a Python function to sort a list

 Create a marketing email for a SaaS product

 Compare REST vs GraphQL APIs

Send

### Google: Nano Banana 2 (Gemini 3.1 Flash Image)

google google-gemini-3.1-flash-image

Copy model ID

PricingInput $0.50 / 1M tokens

Output $3.00 / 1M tokens

API EndpointsOpenAI Compatible

`https://modelslab.com/api/v7/llm/chat/completions`Endpoint

Anthropic Compatible

`https://modelslab.com/api/v7/llm/v1/messages`Messages

`https://modelslab.com/api/v7/llm/v1/messages/count_tokens`Count Tokens

`https://modelslab.com/api/v7/llm/v1/models`Models

Use with Claude Code

cURL Example

ParametersSystem MessageYou are a helpful AI assistant specialized in providing accurate and detailed responses.

Temperature0.7

Max Tokens1000

Top P0.9

Frequency Penalty0

Presence Penalty0

Model Info

Support

Related Models
---

Discover similar models you might be interested in

 [View all LLM Models](https://modelslab-frontend-v2-927501783998.us-east4.run.app/models?feature=llmaster)

[#### byteplus/Seed 1.8

seed-1.8

From $3.00/M tokens](https://modelslab-frontend-v2-927501783998.us-east4.run.app/models/byteplus/seed-1.8)

[#### open\_router/MoonshotAI: Kimi K2.5

moonshotai-kimi-k2.5

From $1.20/M tokens](https://modelslab-frontend-v2-927501783998.us-east4.run.app/models/open_router/moonshotai-kimi-k2.5)

[#### open\_router/MiniMax: MiniMax M3

minimax-minimax-m3

From $0.75/M tokens](https://modelslab-frontend-v2-927501783998.us-east4.run.app/models/open_router/minimax-minimax-m3)

[#### open\_router/Amazon: Nova Premier 1.0

amazon-nova-premier-v1

From $7.50/M tokens](https://modelslab-frontend-v2-927501783998.us-east4.run.app/models/open_router/amazon-nova-premier-v1)

[#### open\_router/OpenAI: GPT-4o-mini

openai-gpt-4o-mini

From $0.38/M tokens](https://modelslab-frontend-v2-927501783998.us-east4.run.app/models/open_router/openai-gpt-4o-mini)

[#### open\_router/Cohere: Command R7B (12-2024)

cohere-command-r7b-12-2024

From $0.09/M tokens](https://modelslab-frontend-v2-927501783998.us-east4.run.app/models/open_router/cohere-command-r7b-12-2024)

[#### google\_deepmind/Gemma 3N E4B Instruct

google-gemma-3n-E4B-it

From $0.09/M tokens](https://modelslab-frontend-v2-927501783998.us-east4.run.app/models/google_deepmind/google-gemma-3n-E4B-it)

[#### open\_router/inclusionAI: Ring-2.6-1T

inclusionai-ring-2.6-1t

From $0.35/M tokens](https://modelslab-frontend-v2-927501783998.us-east4.run.app/models/open_router/inclusionai-ring-2.6-1t)

[#### open\_router/Qwen: Qwen3 Coder Next

qwen-qwen3-coder-next

From $0.46/M tokens](https://modelslab-frontend-v2-927501783998.us-east4.run.app/models/open_router/qwen-qwen3-coder-next)

[#### open\_router/DeepSeek: R1

deepseek-deepseek-r1

From $1.60/M tokens](https://modelslab-frontend-v2-927501783998.us-east4.run.app/models/open_router/deepseek-deepseek-r1)

[#### open\_router/Qwen: Qwen3 Coder Flash

qwen-qwen3-coder-flash

From $0.58/M tokens](https://modelslab-frontend-v2-927501783998.us-east4.run.app/models/open_router/qwen-qwen3-coder-flash)

[#### open\_router/Google: Gemini 3.1 Pro Preview Custom Tools

google-gemini-3.1-pro-preview-customtools

From $7.00/M tokens](https://modelslab-frontend-v2-927501783998.us-east4.run.app/models/open_router/google-gemini-3.1-pro-preview-customtools)

[#### open\_router/Mistral: Codestral 2508

mistralai-codestral-2508

From $0.60/M tokens](https://modelslab-frontend-v2-927501783998.us-east4.run.app/models/open_router/mistralai-codestral-2508)

[#### open\_router/Nous: Hermes 4 405B

nousresearch-hermes-4-405b

From $2.00/M tokens](https://modelslab-frontend-v2-927501783998.us-east4.run.app/models/open_router/nousresearch-hermes-4-405b)

[#### open\_router/Mistral: Mistral Small 4

mistralai-mistral-small-2603

From $0.38/M tokens](https://modelslab-frontend-v2-927501783998.us-east4.run.app/models/open_router/mistralai-mistral-small-2603)

[#### openai/GPT 5.1

gpt5.1

From $5.63/M tokens](https://modelslab-frontend-v2-927501783998.us-east4.run.app/models/openai/gpt5.1)

[#### open\_router/MiniMax: MiniMax M2.7

minimax-minimax-m2.7

From $0.45/M tokens](https://modelslab-frontend-v2-927501783998.us-east4.run.app/models/open_router/minimax-minimax-m2.7)

[#### openai/GPT-5.1-Codex-Max

gpt-5.1-codex-max

From $5.63/M tokens](https://modelslab-frontend-v2-927501783998.us-east4.run.app/models/openai/gpt-5.1-codex-max)

Open Source Alternatives
---

Explore open-source models that offer similar capabilities with full transparency and flexibility

 [View all open source models](https://modelslab-frontend-v2-927501783998.us-east4.run.app/models?feature=llm&provider=open-source-models)

[MU

Popular](https://modelslab-frontend-v2-927501783998.us-east4.run.app/models/modelslab/uncensored-chat)[ModelsLab](https://modelslab-frontend-v2-927501783998.us-east4.run.app/models/modelslab)

 [Modelslab: Uncensored Chat

Open Source Model](https://modelslab-frontend-v2-927501783998.us-east4.run.app/models/modelslab/uncensored-chat)

About Google: Nano Banana 2 (Gemini 3.1 Flash Image)
---

Gemini 3.1 Flash Image, a.k.a. "Nano Banana 2," is Google’s latest state of the art image generation and editing model, delivering Pro-level visual quality at Flash speed. It combines advanced...

### Technical Specifications

Model IDgoogle-gemini-3.1-flash-image

CategoryLLM Models

TaskText Generation

Price$1.75 per million tokens

AddedJune 18, 2026

### Key Features

- Chat completion and multi-turn conversation API
- Streaming response with token-by-token output
- Function calling and tool use support
- System prompts and role-based messaging
- JSON mode and structured output

### Quick Start

Integrate Google: Nano Banana 2 (Gemini 3.1 Flash Image) into your application with a single API call. Get your API key from the [pricing page](https://modelslab-frontend-v2-927501783998.us-east4.run.app/pricing) to get started.

PythonJavaScriptcURLPHP

```
<code>import requests
import json

url = "https://modelslab.com/api/v7/llm/chat/completions"

headers = {
    "Content-Type": "application/json"
}

data = {
        "model_id": "google-gemini-3.1-flash-image",
        "messages": [
            {
                "role": "user",
                "content": "Hello!"
            }
        ],
        "max_tokens": 1000,
        "key": "YOUR_API_KEY"
    }

try:
    response = requests.post(url, headers=headers, json=data)
    response.raise_for_status()  # Raises an HTTPError for bad responses (4XX or 5XX)
    result = response.json()
    print("API Response:")
    print(json.dumps(result, indent=2))
except requests.exceptions.HTTPError as http_err:
    print(f"HTTP error occurred: {http_err} - {response.text}")
except Exception as err:
    print(f"Other error occurred: {err}")</code>
```

### Pricing

Google: Nano Banana 2 (Gemini 3.1 Flash Image) API costs $1.750000 per million tokens. Pay only for what you use with no minimum commitments. [View pricing plans](https://modelslab-frontend-v2-927501783998.us-east4.run.app/pricing)

### Use Cases

- AI chatbots and virtual assistants
- Code generation and developer tools
- Content writing and copywriting automation
- Data analysis, summarization, and extraction

[Browse LLM Models](https://modelslab-frontend-v2-927501783998.us-east4.run.app/models?feature=llmaster) [More from Google](https://modelslab-frontend-v2-927501783998.us-east4.run.app/models/open_router) [View Pricing](https://modelslab-frontend-v2-927501783998.us-east4.run.app/pricing)

Google: Nano Banana 2 (Gemini 3.1 Flash Image) FAQ
---

### What is Google: Nano Banana 2 (Gemini 3.1 Flash Image)?

Gemini 3.1 Flash Image, a.k.a. "Nano Banana 2," is Google’s latest state of the art image generation and editing model, delivering Pro-level visual quality at Flash speed. It combines advanced...

### How do I use the Google: Nano Banana 2 (Gemini 3.1 Flash Image) API?

You can integrate Google: Nano Banana 2 (Gemini 3.1 Flash Image) into your application with a single API call. Sign up on ModelsLab to get your API key, then use the model ID "google-gemini-3.1-flash-image" in your API requests. We provide SDKs for Python, JavaScript, and cURL examples in the API documentation.

### How much does Google: Nano Banana 2 (Gemini 3.1 Flash Image) cost?

Google: Nano Banana 2 (Gemini 3.1 Flash Image) costs $1.750000 per million tokens. ModelsLab uses pay-per-use pricing with no minimum commitments. A free tier is available to get started.

### What is the Google: Nano Banana 2 (Gemini 3.1 Flash Image) model ID?

The model ID for Google: Nano Banana 2 (Gemini 3.1 Flash Image) is "google-gemini-3.1-flash-image". Use this ID in your API requests to specify this model.

### Does Google: Nano Banana 2 (Gemini 3.1 Flash Image) have a free tier?

Yes, ModelsLab offers a free tier that lets you try Google: Nano Banana 2 (Gemini 3.1 Flash Image) and other AI models. Sign up to get free API credits and start building immediately.

---

*This markdown version is optimized for AI agents and LLMs.*

**Links:**
- [Website](https://modelslab.com)
- [API Documentation](https://docs.modelslab.com)
- [Blog](https://modelslab.com/blog)

---
*Generated by ModelsLab - 2026-06-30*