Skip to content
VECTOR WIREAI INTELLIGENCE
UTC

Gemma 4 31B vs GPT-5

Google · released

Wins 1 of 8 areas

Following instructions

OpenAI · released

Wins 7 of 8 areas

Coding · Agents · Reasoning · Facts · Images and charts · Math · Long documents

GPT-5 is the stronger all-rounder.Gemma 4 31B is cheaper and better at following instructions.

Scores updated · 40 tests both models report · How we compare

What it costs

Prices per million tokens, roughly 750,000 words. The bars show the cost of a million tokens read plus a million written.

Gemma 4 31B$0.17 to read · $0.40 to write$0.57Price from Artificial Analysis
GPT-5$1.25 to read · $10.00 to write$11Price from Artificial Analysis

Gemma 4 31B costs 95% less for the same work.

The biggest differences

The three tests each model wins by the widest margin. Scores are out of 100.

Where GPT-5 pulls ahead

  • Short factual questions, answered correctlySimpleQA Verified+39.7points aheadGPT-550.1Gemma 4 31B10.4
  • Fixes real GitHub issues in Python projectsSWE-bench Verified+22.9points aheadGPT-574.9Gemma 4 31B52
  • Answers hard knowledge questions correctlyAA-Omniscience · Accuracy+20.3points aheadGPT-540.3Gemma 4 31B20

Where Gemma 4 31B pulls ahead

  • Command-line tasks in a real terminalTerminal-Bench 2.1+8.2points aheadGemma 4 31B43.4GPT-535.2
  • Hard command-line tasks in a real terminalTerminal-Bench Hard+3.8points aheadGemma 4 31B36.4GPT-532.6
  • Code for real scientific research problemsSciCode+2.6points aheadGemma 4 31B45.5GPT-542.9

Every test, side by side

All 40 tests both models report. The winning score is in its model's colour; marks a score checked independently.

CodingGPT-5

Full coding ranking

AgentsGPT-5

Full agents ranking

ReasoningGPT-5

Full reasoning ranking

FactsGPT-5

Full facts ranking

Images and chartsGPT-5

Full images and charts ranking

MathGPT-5

Full math ranking

Long documentsGPT-5
  • AA-LCRGPT-5 by 8.569.778.2+8.5

Full long documents ranking

Following instructionsGemma 4 31B
  • IFBenchGemma 4 31B by 2.575.673.1+2.5

Full following instructions ranking

Other results16 tests, not counted

Tests outside the eight areas. They are not counted above: several are summary scores built from other tests, or the same test under another name.

Questions people ask

Which is better, Gemma 4 31B or GPT-5?

GPT-5 wins seven of the eight areas we test: coding, agents, reasoning, facts, images and charts, math and long documents. Gemma 4 31B wins following instructions, and costs 95% less.

Which is better for coding?

GPT-5. It wins 5 of the 8 coding tests both models report; Gemma 4 31B wins 3.

Which is cheaper?

Gemma 4 31B costs $0.17 per million input tokens and $0.40 per million output tokens; GPT-5 costs $1.25 and $10.00. That makes Gemma 4 31B about 95% cheaper for the same work.

How do you compare the two?

We use the 40 benchmark tests both models have published scores on. The verdict counts the 24 tests in the eight capability areas, and a gap under one point (ten on rating-style scales) counts as a tie. The other 16 are listed but not counted, because several are summary scores or repeat a test. Each score is the one shown on the model's own page.