Gemma 4 31B — VRAM, Speed & Local Setup

Written by Jakub Rusinowski · Last updated March 31, 2026

Model libraryGemma 4 → Gemma 4 31B

Gemma 4's flagship open-weight model. Full dense 31B with text + image + audio + video multimodal capability — the only sub-50B open model with native video understanding. Scores 92% on MMLU and 86.4% on HumanEval, rivalling GPT-4o on most benchmarks. Needs ~18–20 GB at Q4_K_M (fits on RTX 3090/4090 or 24 GB Mac). Apache 2.0 licensed.

Gemma 4 31B needs about 20 GB of VRAM at Q4_K_M — quantized weights plus framework overhead, before any KV cache. On Apple Silicon that figure comes out of unified memory.

Specifications

Parameters31 Billion
Context window256,000
ArchitectureDense Transformer + Full Multimodal Encoder (image + audio + video)
ProviderGoogle
LicenceApache 2.0
Specified atQ4_K_M
System RAM40 GB
Record updated2026-03-31

Licence

Apache-2.0commercial use permitted. Commercial use permitted. No usage restrictions beyond attribution.

VRAM and Speed by Quantization

Modelled on a reference NVIDIA RTX 4090 (24 GB), with no KV cache (this record has no published architecture). Speed figures are ESTIMATES from the memory-bandwidth roofline described on the methodology page, not benchmarks we ran — rows marked measured come from published or reader-submitted runs. VRAM here includes the KV cache, so it reads higher than the headline figure above, which does not.

QuantWeightsVRAM neededEst. speedFit on 24 GB
Q2_K10.2 GB11.0 GB~59 tok/s (est.)Fits comfortably
Q3_K_M13.2 GB14.0 GB~48 tok/s (est.)Fits comfortably
Q4_K_M18.7 GB19.5 GB~35 tok/s (est.)Fits comfortably
Q5_K_M22.0 GB22.8 GB~31 tok/s (est.)Tight fit
Q6_K25.4 GB26.2 GB~4 tok/s (est.)Offloads to system RAM (slow)
Q8_032.9 GB33.7 GB~3 tok/s (est.)Offloads to system RAM (slow)
F1662.0 GB62.8 GBWon't fit

Want the memory numbers alone, at every quantization level and your own context length? Use the Gemma 4 31B VRAM calculator.

Buy This HardwareAMD Radeon RX 7900 XT 20GB — 20 GB VRAM · 315 W board powerDeploy in the Cloud NowRTX 4090 on RunPod — from $0.34/hr · rate checked 2026-07

or compare on Vast.ai from $0.35/hr (typical low · varies)

As an Amazon Associate we earn from qualifying purchases. Cloud GPU links are referral links — we may earn a commission at no extra cost to you.

Recommended GPU

The cheapest catalogued GPU that runs Gemma 4 31B is the AMD Radeon RX 7900 XT (20 GB).

Affiliate disclosure: Some links on this page are affiliate links — if you buy through them, LLM Configurator may earn a commission at no extra cost to you. As an Amazon Associate, LLM Configurator earns from qualifying purchases.
AMD Radeon RX 7900 XT 20GB
20 GB VRAM · 315 W board power
2026 prices are volatile — check the current listing.
Check price on Amazon

How to Run Gemma 4 31B

Install Ollama, then run:

ollama run gemma4:31b

Weights on Hugging Face: google/gemma-4-31B-it.

Published Benchmark Scores

Quality scores as published by the model's authors or an independent evaluator — not throughput, and not measured by us.

BenchmarkScoreProvenance
MMLU92.1 / 100 %reported
HumanEval86.4 / 100 %reported
MATH80.3 / 100 %reported
MMMU (Multimodal)74.8 / 100 %reported

Best for: reasoning, full multimodal, video analysis, coding, long context, near frontier.

Can I Run Gemma 4 31B on My GPU?

Other Gemma 4 Sizes

Gemma 4 31B — Frequently Asked Questions

How much VRAM does Gemma 4 31B need?
About 20 GB at Q4_K_M — quantized weights plus framework overhead, before any KV cache. The cache grows with context length and is added on top; the table above folds it in. Apple Silicon counts unified memory toward the same figure.
Does Gemma 4 31B run on an RTX 4090 (24 GB)?
Yes. Gemma 4 31B needs about 20 GB at Q4_K_M, inside a 24 GB card, at an estimated 35 tokens/sec.
How do I run Gemma 4 31B locally?
Install Ollama and run `ollama run gemma4:31b`. That pulls the weights and starts a local OpenAI-compatible endpoint; after the download nothing leaves the machine.
What other sizes does Gemma 4 come in?
Gemma 4 E2B (4 GB), Gemma 4 E4B (6 GB), Gemma 4 26B-A4B (16 GB), Gemma 4 31B (20 GB), Gemma 4 12B (Unified) (8 GB). Every size shares the family's training and licence; the larger ones score higher and need proportionally more memory.

← All Gemma 4 models | VRAM calculator | Build a PC for this model | Check your own hardware