Skip to main content
kRouter
All providers

Free credits / metered

gemini/

Gemini

Direct Gemini API — 15 RPM, 1M tokens/day free.

ai.google.dev

Quick setup

  1. Open the kRouter dashboard at http://localhost:20128

  2. Go to Providers → click Gemini

  3. Paste your API key, click Save

  4. Test the connection

Use in your IDE

Point any OpenAI-compatible client at kRouter using your local API key.

ide configbash
# Endpoint
http://localhost:20128/v1

# API key (from Dashboard → API Keys)
sk-krouter-XXXX

# Model
gemini/gemini-2.5-pro

How Gemini billing works with kRouter

Gemini gives you free starting credits, then bills per token. kRouter tracks the remaining quota and fails over to another provider before you hit a wall. kRouter authenticates it via apikey. 20 models are routable as gemini/<model>.

Through kRouter, Gemini serves chat and code completion, embeddings, exposed on /v1/embeddings, image generation, exposed on /v1/images/generations, image understanding (OCR / vision-to-text), web search, exposed on /v1/search so an agent can look things up mid-conversation, text-to-speech, exposed on /v1/audio/speech, speech-to-text, exposed on /v1/audio/transcriptions. Requests reach it through the same local OpenAI-compatible endpoint as every other provider, so switching to or from Gemini is a one-line model change in your client rather than a rewrite.

Gemini models & pricing

Prices are USD per 1M tokens, cheapest first. kRouter bills nothing on top; this is the provider's own rate.

ModelRoute asInput /1MOutput /1M
Gemini 2.5 Flash Litegemini/gemini-2.5-flash-lite$0.15$1.25
Gemini 2.0 Flash Litegemini/gemini-2.0-flash-lite$0.15$1.25
Gemini 2.5 Flash Lite (Cheapest)gemini/gemini-2.5-flash-lite$0.15$1.25
Gemini 2.5 Flashgemini/gemini-2.5-flash$0.30$2.50
Gemini 2.0 Flashgemini/gemini-2.0-flash$0.30$2.50
Gemini 2.5 Flash Image (Nano Banana)gemini/gemini-2.5-flash-image$0.30$2.50
Gemini 2.5 Flashgemini/gemini-2.5-flash$0.30$2.50
Gemini 2.0 Flashgemini/gemini-2.0-flash$0.30$2.50
Gemini 3.1 Pro Previewgemini/gemini-3.1-pro-preview$0.50$3.00
Gemini 3.1 Flash Lite Previewgemini/gemini-3.1-flash-lite-preview$0.50$3.00
Gemini 3 Flash Previewgemini/gemini-3-flash-preview$0.50$3.00
Gemini Embedding 2 Previewgemini/gemini-embedding-2-preview$0.50$3.00
Gemini Embedding 001gemini/gemini-embedding-001$0.50$3.00
Gemini 3.1 Flash Image (Nano Banana 2)gemini/gemini-3.1-flash-image-preview$0.50$3.00
Gemini 3 Pro Image (Nano Banana Pro)gemini/gemini-3-pro-image-preview$0.50$3.00
Gemini 2.5 Progemini/gemini-2.5-pro$2.00$12.00
Gemini 2.5 Pro (Best)gemini/gemini-2.5-pro$2.00$12.00
Gemma 4 31B ITgemini/gemma-4-31b-it——
Text Embedding 005gemini/text-embedding-005——
Text Embedding 004 (Legacy)gemini/text-embedding-004——

Gemini FAQ

Is Gemini free through kRouter?

Gemini is pay-per-token: you bring your own API key and are billed by Gemini at their rates. kRouter adds nothing on top and is free and MIT-licensed.

How do I use Gemini with Claude Code or Cursor?

Connect Gemini in the kRouter dashboard, then point your tool at kRouter's local endpoint (http://localhost:20128/v1) with a kRouter API key. Any OpenAI-compatible client works, and models are addressed as gemini/<model>.

Which Gemini models can kRouter route to?

20 models, including Gemini 3.1 Pro Preview, Gemini 3.1 Flash Lite Preview, Gemini 3 Flash Preview. Every one is addressed as gemini/<model> from any client.

What happens when Gemini is rate limited?

kRouter detects the limit, parks that account until its real reset time, and fails over to your next connected account or provider — so the request still completes instead of erroring.