Models / Gemini / Gemma 4 31B
Gemini

Gemma 4 31B

BYOKOpen weightsReleased 2 Apr 2026

Google's open-weight model, released April 2026, accepting text, image and video input. It is very cheap and efficient but ranks low on most benchmarks.

Read the full description ↓

Spec sheet

Family
Gemini
Released
2 Apr 20268 months ago
Weights
Open
Context window
262k tokens
Largest response
33k tokens
Accepts
text, image, video
Supports
tools, reasoning, structured output
Knowledge cutoff
–
Intelligence index
51.2#83
Input price
$0.12 / 1M
Output price
$0.35 / 1M
Blended price (3:1)
$0.18 / 1M
Index points per $
288.5#7
Speed
32.5 tokens/sec#164
Popularity
#35 of 194by usage
Providers
3
Weights on
google/gemma-4-31B-it

Benchmarks

Score · rank among models tested

The tick on each bar marks the registry median; hover over a bar for the numbers. Sources and how the index is computed: methodology.

Providers and prices

$ per 1M tokens · from genai-prices
ProviderGatewayPydantic AI model stringInputCached inputOutputBlended
Doublewordgateway/doubleword:google/gemma-4-31B-it $0.12–$0.35$0.18
NovitaBYOK–$0.14–$0.4$0.21
OpenRouterBYOKopenrouter:google/gemma-4-31b-it $0.15$0.06$0.4$0.21

The cheapest provider is highlighted. Blended price assumes three input tokens for each output token.

Example code

# /// script
# dependencies = ["pydantic-ai"]
# ///
import os

from pydantic_ai import Agent

os.environ['PYDANTIC_AI_GATEWAY_API_KEY'] = '...'

agent = Agent('gateway/doubleword:google/gemma-4-31B-it', instructions='Be concise, reply with one sentence.')

result = agent.run_sync('Where does "hello world" come from?')
print(result.output)

Ask Gemma 4 31B a question with a Pydantic AI agent and print the answer. Run it with uv run hello.py.

Compare

Gemma 4 31BvsDeepSeek V3.2 Exp
Intelligence index
205590$0.1$1$10DeepSeek V3.2 Exp: 51.4 at $0.3 blendedGemma 4 31B: 51.2 at $0.18 blended
GPQA Diamond
5075100$0.1$1$10Gemma 4 31B: 75.8% at $0.18 blended
OTIS Mock AIME
4070100$0.1$1$10Gemma 4 31B: 73.3% at $0.18 blended
SimpleQA Verified
1055100$0.1$1$10Gemma 4 31B: 10.4% at $0.18 blended
SciCode
204570$0.1$1$10DeepSeek V3.2 Exp: 38.9% at $0.3 blendedGemma 4 31B: 45.5% at $0.18 blended
WebDev Arena
122015251830$0.1$1$10DeepSeek V3.2 Exp: 1367 at $0.3 blendedGemma 4 31B: 1364.1 at $0.18 blended
LMArena text
128014101540$0.1$1$10DeepSeek V3.2 Exp: 1424.9 at $0.3 blendedGemma 4 31B: 1442.9 at $0.18 blended
Epoch Capabilities Index
120150180$0.1$1$10DeepSeek V3.2 Exp: 144.4 at $0.3 blendedGemma 4 31B: 144.1 at $0.18 blended

Score against blended price per 1M tokens (log scale). Gemma 4 31B   DeepSeek V3.2 Exp   other models

Intelligence indexOur composite of the benchmarks below, 0-100
Gemma 4 31B51.2
DeepSeek V3.2 Exp51.4
GPQA DiamondGraduate-level science questions, multiple choice
Gemma 4 31B75.8%
DeepSeek V3.2 Exp–
OTIS Mock AIMECompetition mathematics problems with exact answers
Gemma 4 31B73.3%
DeepSeek V3.2 Exp–
SimpleQA VerifiedShort factual questions answered from memory, without search
Gemma 4 31B10.4%
DeepSeek V3.2 Exp–
SciCodeScientific programming problems written by researchers
Gemma 4 31B45.5%
DeepSeek V3.2 Exp38.9%
WebDev ArenaRating from human votes on web apps the models built
Gemma 4 31B1364.1
DeepSeek V3.2 Exp1367
LMArena textRating from blind human votes between pairs of chat responses
Gemma 4 31B1442.9
DeepSeek V3.2 Exp1424.9
Epoch Capabilities IndexEpoch AI's own composite across about 40 benchmarks; shown for comparison, not part of our index
Gemma 4 31B144.1
DeepSeek V3.2 Exp144.4
Input pricePer 1M tokens, lower is better
Gemma 4 31B$0.12
DeepSeek V3.2 Exp$0.27
Output pricePer 1M tokens, lower is better
Gemma 4 31B$0.35
DeepSeek V3.2 Exp$0.41
EfficiencyIndex points per blended $
Gemma 4 31B289
DeepSeek V3.2 Exp169
SpeedOutput tokens per second
Gemma 4 31B32.5 t/s
DeepSeek V3.2 Exp15 t/s
Context windowTokens
Gemma 4 31B262k
DeepSeek V3.2 Exp128k
Model stringFor Pydantic AI
Gemma 4 31Bgateway/doubleword:google/gemma-4-31B-it
DeepSeek V3.2 Expdeepseek:deepseek-v3.2-exp

About Gemma 4 31B

Description written by an LLM from the data on this page

Google's open-weight model, released April 2026, accepting text, image and video input. It is very cheap and efficient but ranks low on most benchmarks.

Gemma 4 31B is an open-weight model from Google, released April 2026, that accepts text, image and video and offers a 262k context window with up to 32k output tokens. It supports tool calling, structured output and a reasoning mode. Its main appeal is cost: input is $0.12 and output $0.35 per million tokens, a blended $0.18 against a registry median of about $1.01, which gives it seventh place for intelligence per dollar.

On capability it sits in the lower part of the registry. Its intelligence index is 51.2 against a median of 59.5, ranking 86th of 114. It scores 75.8% on GPQA Diamond and 73.3% on OTIS Mock AIME, both well below median, and 10.4% on SimpleQA Verified, last of 76 models tested. Its LMArena text rating of 1442.9 is slightly above the median, so chat preference is roughly typical.

Strengths

  • Seventh of 194 for intelligence per dollar, at 288.5 points
  • Blended price $0.18 per million tokens, 24th cheapest of 194
  • 262k context window with image and video input
  • LMArena text rating 1443, 50th of 114, slightly above median

Weaknesses

  • Intelligence index 51.2, 86th of 114, below median 59.5
  • SimpleQA Verified 10.4%, last of 76 models tested
  • GPQA Diamond 75.8%, 85th of 94; OTIS Mock AIME 84th of 95

Best for

Low-cost, high-volume agent tasks needing tool calling, long context or image input, where top benchmark scores matter less.

One key, every model

Pydantic AI Gateway gives you the models marked with a single API key, spending limits and Logfire tracing. Bring your own key for the rest.

Start free  Read the docs