This model was retired on 2026-08-27. The pricing below is the last-known rate, kept for migration reference.
Context
262K
Max output
262K
Serving providers
8
Cheapest input
$0.09 /1M
Prices are on-demand list rates. Enterprise commitments (committed-use discounts, provisioned throughput, negotiated rates) can be materially lower.
Pricing by serving provider
last-known · per 1M tokens · click a provider to expand| Serving provider | Input /1M | Output /1M | Endpoints | |||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| OpenRouter | $0.09 | $0.34 | 1 | |||||||||||||||||||||
| ||||||||||||||||||||||||
| Wandb | $0.10 | $0.34 | 1 | |||||||||||||||||||||
| ||||||||||||||||||||||||
| DeepInfra | $0.13 | $0.38 | 1 | |||||||||||||||||||||
| ||||||||||||||||||||||||
| Novita | $0.14 | $0.40 | 1 | |||||||||||||||||||||
| ||||||||||||||||||||||||
| Tensormesh | $0.14 | $0.56 | 1 | |||||||||||||||||||||
| ||||||||||||||||||||||||
| Libertai | $0.15 | $0.40 | 1 | |||||||||||||||||||||
| ||||||||||||||||||||||||
| Together AI | $0.28 | $0.86 | 1 | |||||||||||||||||||||
| ||||||||||||||||||||||||
| SambaNova | $0.38 | $1.15 | 1 | |||||||||||||||||||||
| ||||||||||||||||||||||||
Price history
input + output $/1M since we started tracking Input Output
Input down 36% since first tracked
Cost calculator
estimate your monthly spend on this model$45
estimated / month
Model IDs
copy the exact identifier for your platformgoogle/gemma-4-31b-itwandb/google/gemma-4-31B-itdeepinfra/google/gemma-4-31B-itnovita/google/gemma-4-31b-ittensormesh/google/gemma-4-31B-itlibertai/gemma-4-31b-ittogether_ai/pearl-ai/gemma-4-31b-itsambanova/gemma-4-31B-it
Frequently asked questions
Gemma 4 31B pricing, context and availabilityIs Gemma 4 31B still available?
Gemma 4 31B was retired on 2026-08-27. The pricing on this page is the last-known rate, kept for migration reference.
How much did Gemma 4 31B cost?
Gemma 4 31B's last-known pricing, before it was retired on 2026-08-27, was $0.09 per 1M input tokens and $0.34 per 1M output tokens.
What was the context window of Gemma 4 31B?
Gemma 4 31B had a 262K token context window and could return up to 262K output tokens.
What could Gemma 4 31B do?
Gemma 4 31B supported image input (vision), tool use, reasoning, prompt caching and structured output.
Other Google models
compare pricing across the Google lineupGemma 3 27B$0.00/1M · 8 providersGemini 2.5 Flash$0.15/1M · 8 providersGemini 2.5 Pro$1.25/1M · 7 providersGemma 3 12B$0.05/1M · 5 providersGemma 4 26B A4B $0.07/1M · 5 providersGemini 3.1 Flash Lite$0.25/1M · 5 providersGemini 3.7 Flash$0.38/1M · 5 providersGemini 3 Flash Preview$0.50/1M · 5 providers
Pricing verified against LiteLLM + OpenRouter + provider pages · refreshed daily
Every weekday
AI moves fast. Here's your debrief.
News, analysis, tools, and more.
For people who build with AI