whatmodel.sh / Gemma 3 4B
Gemma 3 4B
↗ share
+ contribute
Gemma 3 4B is an open-weights language model from Google, released March 2025. Its published size is 4.3B parameters and a 131k-token context window. Licence: gemma.
Score within the LMArena (text) comparison set only.
$ how it compares
The LLMs ranked either side of Gemma 3 4B, out of 897 with a score, then more from Google.
| # | model | score | where | ||
|---|---|---|---|---|---|
| 582 | 45±2 | local | |||
| 583 | 45±2 | local | |||
| 584 | 45±1 | api $0.063/M +local | |||
| 585 | 45±1 | api $0.13/M +local | |||
| 586 | 45±1 | local | |||
| more from Google | |||||
| 3 | 84±1 | api $4.00/M | |||
| 9 | 81±1 | api $4.00/M | |||
| 14 | 79±2 | api $3.00/M | |||
$ what it's good at
agent tasks▁▁▃▆█▄▅▅▃▃▂▁ #303 of 319 * · 2.3% of its score · 2 tests
Beats DBRX Instruct, QwQ-32B-Preview, DeepSeek-Coder-V2 Lite Instruct (16B-A2.4B) here, though they rank higher overall. Trails Granite 4.0 H 350M, ChatGLM3-6B, Qwen3 0.6B here, though they rank lower overall.
| test | result | vs the others in its run | counts |
|---|---|---|---|
| BFCL V4 (December 2025 archive) | 19.6% ✎ | ▁▁▁▃██▅▅▆▂▂▂ beats 5/77 | 1.4% |
| BFCL v3 | 39.6% ✎ | ▁▁▁▁▃▃▅█▅▄▁▁ beats 14/114 | 0.9% |
coding▁▁▁▃▆▇█▆▆▃▃▁ #376 of 474 · 11% of its score · 5 tests
Beats LFM2.5 8B-A1B, Qwen3-VL 2B Thinking, DeepSeek R1 Distill Qwen 7B here, though they rank higher overall. Trails Qwen2.5 1.5B Instruct, Code Tulu 2 13B, Phi-3-mini-128k-instruct (Apr 2024) here, though they rank lower overall.
| test | result | vs the others in its run | counts |
|---|---|---|---|
| HumanEval lab | 71.3% ✎ | ▁▁▁▁▂▂▆▆█▅▂▁ beats 141/205 | 4.7% |
| MBPP lab | 63.2% ✎ | ▁▁▁▄▅█▆▅▄▁▂▁ beats 58/86 | 2.2% |
| VisEditBench strict pass rate (1,395 visualization-code editing tasks) | 21.3% ✎ | ▄··█·▄··▄█·▄ beats 0/7 | 1.8% |
| LiveCodeBench (version unspecified) lab | 12.6% ✎ | ▁···▃▁▁█▇▃▄▁ beats 1/38 | 1.4% |
| BIRD-SQL (dev) lab | 36.3% ✎ | ▂·······▃▂█▆ beats 1/11 | 0.7% |
chat & writing▁▁▁▃▅▄▆█▇▇▇▃ #230 of 405 · 7.0% of its score · 3 tests
Beats Granite 4.2 8B, Mistral Small 4 (119B-A6.5B), Olmo 3.1 32B Think here, though they rank higher overall. Trails LFM2.5 1.2B Instruct here, though they rank lower overall.
| test | result | vs the others in its run | counts |
|---|---|---|---|
| LMArena (text) | 1303.3 ✎ | ▁▁▁▂▃▂▃▆▆▇█▃ beats 130/388 | 3.8% |
| IFEval mean of four measures | 76.8% ✎ | █··▄▄·▄····▄ beats 2/5 | 2.3% |
| IFEval (aggregation unspecified) lab | 90.2% ✎ | ▁▂▄▂▂▄▆██▅▂▁ beats 118/145 | 0.8% |
math▁▁▃▅█▆▅█▄▁▁▁ #276 of 440 · 11% of its score · 6 tests
Beats GPT-4o (2024-11-20), GPT-4 Turbo (2024-04-09), Molmo 2 8B here, though they rank higher overall. Trails DeepSeek R1 Distill Qwen 1.5B, Gemma 7B (base), CodeGemma 7B (v1.0) here, though they rank lower overall.
| test | result | vs the others in its run | counts |
|---|---|---|---|
| GSM8K lab | 89.2% ✎ | ▂▂▂▂▃▄▅▇██▆▄ beats 176/206 | 4.7% |
| MATH (subset unspecified) lab | 75.6% ✎ | ▂▄▄▃█▇▅▆▄▃▄▁ beats 48/80 | 3.1% |
| MathVista (testmini) lab | 50.0% ✎ | ▁··▁▄▄▆▇▄▅█▄ beats 8/48 | 1.5% |
| MATH-500 | 73.2% ✎ | ▃····▃·█···▃ beats 2/5 | 1.4% |
| OTIS mock AIME 2024–2025 | 7.5% ✎ | ▃▃▄▃▃▃▇▆█▄▃▆ beats 43/207 | 0.3% |
| GSM8K loose substring accuracy | 89.9% ✎ | █·█··███···█ beats 5/5 | 0.2% |
vision & documents▃▁▂▂▁▃▄▂▆▇█▄ #153 of 154 · 8.1% of its score · 10 tests
Trails Qwen3.5 0.8B, Qwen2-VL 2B Instruct, Phi-3.5-vision-instruct here, though they rank lower overall.
| test | result | vs the others in its run | counts |
|---|---|---|---|
| VisEditBench strict pass rate (1,395 visualization-code editing tasks) | 21.3% ✎ | ▄··█·▄··▄█·▄ beats 0/7 | 1.8% |
| MathVista (testmini) lab | 50.0% ✎ | ▁··▁▄▄▆▇▄▅█▄ beats 8/48 | 1.5% |
| MMMU (val) lab | 48.8% ✎ | ▁····▁▁▃█▆▆▅ beats 7/53 | 1.4% |
| InfographicVQA lab | 50.0% ✎ | ▃·▃▅█▃▃▃▃▃▃▃ beats 0/13 | 1.1% |
| VQAv2 (val) lab | 62.4% ✎ | ▃▅▃█·▃▅·▃·▃▅ beats 0/13 | 0.6% |
| ChartQA lab | 68.8% ✎ | ▁··▁▁▁▁▃▂▅▅█ beats 5/44 | 0.5% |
| DocVQA lab | 75.8% ✎ | ▃··▃▁▁▁▇█▇▄▅ beats 0/28 | 0.4% |
| VMMU (Vietnamese multimodal understanding and reasoning, mean accuracy over 7 tasks) | 25.4% ✎ | ▅······▃·▅·█ beats 0/7 | 0.4% |
other tests29 not in a task · 64% of its score
| test | result | vs the others in its run | counts |
|---|---|---|---|
| GPQA Diamond +2 | 23.2% ✎ | ▃▁▁▁▂▃▅▄▄▆█▃ beats 4/221 | 8.5% |
| Medmarks-V mean win rate (19 verifiable medical benchmarks, 71 configurations) | 0.3214 ✎ | ▃▄▃▃▇▄█▃▅▁▁▁ beats 0/30 | 7.5% |
| MMLU +1 | 58.4% ✎ | ▄█···█·····▄ beats 0/5 | 7.3% |
| BIG-Bench Hard lab | 72.2% ✎ | ▁▁▁▁▂▄▅▆█▃▃▁ beats 124/155 | 4.6% |
| MMLU-Pro +1 | 34.8% ✎ | ███···██···█ beats 3/5 | 3.5% |
| Medmarks-V weighted mean win rate (61 models, 71 configurations) | 32.1% ✎ | ▃▃▅▂▆▃█▅█▅▃▆ beats 0/34 | 3.1% |
| EQ-Bench 3 (emotional intelligence, judge Elo) | 1118.2 ✎ | ▁·▂▁▄▅▅▃█▄▁▁ beats 15/62 | 2.5% |
| Global-MMLU-Lite lab | 54.5% ✎ | ▂···▃·▂▂▂·██ beats 1/12 | 2.3% |
21 more tests
$ where to run it
Through an API
api · DeepInfra · $0.063/M · $0.05 in / $0.1 out per 1M tokens · 131k context · deepinfra.com ↗ · price sourceUSD per 1M text tokens, standard uncached input and output. Product: Serverless text generation. API model: google/gemma-3-4b-it. Settings: service tier=standard, batch=no, cache=uncached input. Additional/excluded charges: Tools, cache storage, priority service and other modalities excluded.. Currency: USD.
Memory is what a version takes in GPU memory (or a Mac's unified memory) with an 8k-token conversation. With less, it runs partly from system RAM, more slowly. Enter your machine to see what runs at full speed.
llama.cpp · recommended
version
- Install llama.cpp · Homebrew and winget installs name the commands llama-cli and llama-server instead.macOS / Linux
curl -LsSf https://llama.app/install.sh | shWindowsirm https://llama.app/install.ps1 | iex - Run Gemma 3 4B · needs 4.9 GB memory, 3.34 GB download · from huggingface.co/ggml-orgchat in the terminal
llama cli -hf ggml-org/gemma-3-4b-it-GGUF:Q4_K_M - Or start a local server and open the address it prints (http://localhost:9931)
llama serve -hf ggml-org/gemma-3-4b-it-GGUF:Q4_K_M
LM Studio
version
- Install LM Studio · Open the app once before using the lms command.
- Run Gemma 3 4B · needs 4.9 GB memory, 3.34 GB download · from huggingface.co/ggml-org
- Or download it in the terminal
lms get https://huggingface.co/ggml-org/gemma-3-4b-it-GGUF@Q4_K_M -y - Then run lms ls to see its name, and lms chat followed by that name
Ollama
version
- Install Ollama
download it (macOS / Windows) ↗
Linuxcurl -fsSL https://ollama.com/install.sh | sh - Run Gemma 3 4B · needs 4.9 GB memory, 3.35 GB download · from ollama.comchat in the terminal
ollama run gemma3:4b
MLX (Mac)
version
- Install MLX (Mac) · Apple silicon Macs only, text only.with uv
uv tool install mlx-lmorpip install mlx-lm - Run Gemma 3 4B · needs 3.8 GB memory, 2.18 GB download, Mac only · from huggingface.co/Outlier-Aichat in the terminal
mlx_lm.chat --model Outlier-Ai/gemma-3-4b-it-MLX-4bit - Or start an OpenAI-compatible server at http://localhost:8080/v1
mlx_lm.server --model Outlier-Ai/gemma-3-4b-it-MLX-4bit
Model repository and documentation: huggingface.co/google ↗
$ how the score was worked out · Google DeepMind Gemma 3 270M… 38%, LFM2 Technical Report — Liqui… 19%, Medmarks: A Comprehensive Ope… 11% and 14 more
Each result implies a score on its own, after adjusting for how hard its test is and who ran it. The score is their weighted average, with a small pull toward the middle for thinly tested models. Each test's weight is its counts column above; here it's added up by who ran the tests. How it works
$ published speed measurements · 14
Reference results for the hardware, engine and settings below. They aren't verified speeds of the downloads above or predictions for your machine.
| NVIDIA DGX Spark (GB10) | QAT Q4_0 | 81.05 tok/s | llama.cpp 11fb327bf (7941), CUDA · llama-bench; tg32; 32 generated tokens; context depth 0; n_ubatch=2048; flash attention=1; one sequencenotePublished token-generation mean; not prompt processing or aggregate batch throughput. Hardware core count and installed RAM are not inferred. | source ↗ |
| NVIDIA DGX Spark (GB10) | QAT Q4_0 | 76.37 tok/s | llama.cpp 11fb327bf (7941), CUDA · llama-bench; tg32 @ d4096; 32 generated tokens; context depth 4096; n_ubatch=2048; flash attention=1; one sequencenotePublished token-generation mean; not prompt processing or aggregate batch throughput. Hardware core count and installed RAM are not inferred. | source ↗ |
| NVIDIA DGX Spark (GB10) | QAT Q4_0 | 62.28 tok/s | llama.cpp 11fb327bf (7941), CUDA · llama-bench; tg32 @ d32768; 32 generated tokens; context depth 32768; n_ubatch=2048; flash attention=1; one sequencenotePublished token-generation mean; not prompt processing or aggregate batch throughput. Hardware core count and installed RAM are not inferred. | source ↗ |
| Apple M2 Ultra (GPU core count and RAM not specified) | QAT Q4_0 | 134.28 tok/s | llama.cpp b828e18c7 (7948), Metal/BLAS · llama-bench; tg32; 32 generated tokens; context depth 0; n_ubatch=2048; flash attention=1; one sequencenotePublished token-generation mean; not prompt processing or aggregate batch throughput. Hardware core count and installed RAM are not inferred. | source ↗ |
| Apple M2 Ultra (GPU core count and RAM not specified) | QAT Q4_0 | 133.11 tok/s | llama.cpp b828e18c7 (7948), Metal/BLAS · llama-bench; tg32 @ d4096; 32 generated tokens; context depth 4096; n_ubatch=2048; flash attention=1; one sequencenotePublished token-generation mean; not prompt processing or aggregate batch throughput. Hardware core count and installed RAM are not inferred. | source ↗ |
| Apple M2 Ultra (GPU core count and RAM not specified) | QAT Q4_0 | 113.14 tok/s | llama.cpp b828e18c7 (7948), Metal/BLAS · llama-bench; tg32 @ d32768; 32 generated tokens; context depth 32768; n_ubatch=2048; flash attention=1; one sequencenotePublished token-generation mean; not prompt processing or aggregate batch throughput. Hardware core count and installed RAM are not inferred. | source ↗ |
| NVIDIA DGX Spark (GB10) | QAT Q4_0 | 71.61 tok/s | llama.cpp 11fb327bf (7941), CUDA · llama-bench; tg32 @ d8192; 32 generated tokens; context depth 8192; n_ubatch=2048; flash attention=1; one sequencenotePublished token-generation mean; not prompt processing or aggregate batch throughput. Hardware core count and installed RAM are not inferred. | source ↗ |
| NVIDIA DGX Spark (GB10) | QAT Q4_0 | 70.89 tok/s | llama.cpp 11fb327bf (7941), CUDA · llama-bench; tg32 @ d16384; 32 generated tokens; context depth 16384; n_ubatch=2048; flash attention=1; one sequencenotePublished token-generation mean; not prompt processing or aggregate batch throughput. Hardware core count and installed RAM are not inferred. | source ↗ |
| Apple M2 Ultra (GPU core count and RAM not specified) | QAT Q4_0 | 125.85 tok/s | llama.cpp b828e18c7 (7948), Metal/BLAS · llama-bench; tg32 @ d8192; 32 generated tokens; context depth 8192; n_ubatch=2048; flash attention=1; one sequencenotePublished token-generation mean; not prompt processing or aggregate batch throughput. Hardware core count and installed RAM are not inferred. | source ↗ |
| Apple M2 Ultra (GPU core count and RAM not specified) | QAT Q4_0 | 125 tok/s | llama.cpp b828e18c7 (7948), Metal/BLAS · llama-bench; tg32 @ d16384; 32 generated tokens; context depth 16384; n_ubatch=2048; flash attention=1; one sequencenotePublished token-generation mean; not prompt processing or aggregate batch throughput. Hardware core count and installed RAM are not inferred. | source ↗ |
| Intel Alder Lake-P GT2 [Iris Xe Graphics] (integrated), 31 GB RAM | q4_k_m | 8.21 tok/s | ollama (version not recorded) · llmfit bench 1.1.6 via Ollama: a warm-up, then 3 runs of up to 300 generated tokens (163 on average); eval_count ÷ eval_duration, generation onlynoteCommunity submission to llmfit on 2026-08-06 (12th Gen Intel(R) Core(TM) i7-1270P, 31 GB RAM, linux); 7.81–8.58 tok/s across runs. | source ↗ |
| Intel Alder Lake-P GT2 [Iris Xe Graphics] (integrated), 31 GB RAM | q4_k_m | 7.88 tok/s | ollama (version not recorded) · llmfit bench 1.1.6 via Ollama: a warm-up, then 3 runs of up to 300 generated tokens (220 on average); eval_count ÷ eval_duration, generation onlynoteCommunity submission to llmfit on 2026-08-12 (12th Gen Intel(R) Core(TM) i7-1270P, 31 GB RAM, linux); 6.74–9.32 tok/s across runs. | source ↗ |
| Intel Alder Lake-P GT2 [Iris Xe Graphics] (integrated), 31 GB RAM | q4_k_m | 8.93 tok/s | ollama (version not recorded) · llmfit bench 1.1.6 via Ollama: a warm-up, then 3 runs of up to 300 generated tokens (218 on average); eval_count ÷ eval_duration, generation onlynoteCommunity submission to llmfit on 2026-08-12 (12th Gen Intel(R) Core(TM) i7-1270P, 31 GB RAM, linux); 8.33–9.65 tok/s across runs. | source ↗ |
| Intel CoffeeLake-S GT2 [UHD Graphics 630] (integrated), 31 GB RAM | q4_k_m | 5.98 tok/s | ollama (version not recorded) · llmfit bench 1.1.12 via Ollama: a warm-up, then 3 runs of up to 300 generated tokens (221 on average); eval_count ÷ eval_duration, generation onlynoteCommunity submission to llmfit on 2026-09-02 (Intel(R) Core(TM) i5-9500T CPU @ 2.20GHz, 31 GB RAM, linux); 5.66–6.49 tok/s across runs. | source ↗ |
$ improve this page
Use a short GitHub form or edit the data through a pull request. Every number needs a source; here's which ones we can use.
data updated · sources and licences · json