Roboflow

Gemma 4 31B vs Grok 4.7

Compare Gemma 4 31B and Grok 4.7 side-by-side.

Compare Gemma 4 31B vs Grok 4.7 live

Run the same image across every model that supports a task and compare their outputs side-by-side.

These models don't share enough common tasks for a side-by-side demo. See the comparison table below for their capabilities.

Models in this comparison

Gemma 4 31B vs Grok 4.7 on Vision Evals

Grok 4.7 scores higher on 5 of the six Vision Evals tasks.

The widest gap is Reasoning, where Grok 4.7 leads 64.2% to 50.8%.

Overall, Gemma 4 31B averages 67.0% (#31 of 54) against 71.9% (#22 of 54) for Grok 4.7.

Gemma 4 31B is cheaper ($0.0012 vs $0.012 per sample), while Grok 4.7 is faster (23.6s vs 28.8s per sample).

Gemma 4 31BGrok 4.7

Gemma 4 31B vs Grok 4.7 Comparison Table

Evals updated September 22, 2026Pricing updated September 22, 2026

PropertyGemma 4 31BGrok 4.7
OrganizationGoogleSpaceXAI
Categoryopenclosed
Modalitymultimodal
Release DateApr 2026Sep 2026
Context Window256K500K
Parameters31B
LicenseApache 2.0Proprietary
Pricing per 1M tokens
Input $/1M$0.090$1.60
Output $/1M$0.340$4.80
Vision Tasks
CaptioningDemo
Chart Question Answering
ClassificationDemo
Document Question Answering
Image Tagging
Multi-Label Classification
Object DetectionDemo
OCRDemo
Vision Language
Visual Question AnsweringDemo
Model Features
Foundation Vision
LLMs with Vision Capabilities
Multimodal Vision
Vision Evalsground-truth scores across 6 vision tasks, pooled at low effort
Overall
67.0%
71.9%
Quantizationsself-hosted
BF1665.3%FP865.1%QAT-W4A1667.0%hardware →
Avg cost / sample$0.0012$0.012
Avg speed / sample28.79s23.55s
By task
Object Detection (low)
48.2%
±0.2, Mean of 3 runs, range 48.0 to 48.4
$0
40.4%
±0.6, Mean of 3 runs, range 39.8 to 41.0
$0.017
Object Detection (high)
41.2%
±1.6, Mean of 3 runs, range 39.6 to 42.8
$0.023
Counting (low)
51.4%
±1.4, Mean of 3 runs, range 50.0 to 52.7
$0
61.7%
±1.3, Mean of 3 runs, range 60.8 to 63.5
$0.0086
Counting (high)
60.8%
±1.3, Mean of 3 runs, range 59.5 to 62.2
$0.013
Identification (low)
80.2%
±3.1, Mean of 3 runs, range 78.1 to 84.4
$0
87.5%
±3.1, Mean of 3 runs, range 84.4 to 90.6
$0.0050
Identification (high)
80.2%
±1.6, Mean of 3 runs, range 78.1 to 81.3
$0.0074
OCR (low)
90.8%
±0.2, Mean of 3 runs, range 90.6 to 90.9
$0
92.6%
±0.7, Mean of 3 runs, range 92.1 to 93.4
$0.014
OCR (high)
93.5%
±0.3, Mean of 3 runs, range 93.1 to 93.8
$0.034
Data Extraction (low)
80.4%
±2.6, Mean of 3 runs, range 77.3 to 82.5
$0
84.9%
±2.6, Mean of 3 runs, range 82.5 to 87.6
$0.0048
Data Extraction (high)
87.6%
±1.5, Mean of 3 runs, range 86.6 to 89.7
$0.0054
Reasoning (low)
50.8%
±1.7, Mean of 3 runs, range 49.0 to 52.3
$0
64.2%
±2.3, Mean of 3 runs, range 62.3 to 66.9
$0.012
Reasoning (high)
66.9%
±1.3, Mean of 3 runs, range 65.6 to 68.2
$0.019

Gemma 4 31B vs Grok 4.7: Overview

Gemma 4 31B

Gemma 4 31B is the largest dense model in Google's Gemma 4 family, built from the same research as Gemini 3 and released as open weights under the Apache 2.0 license. It supports a 256K token context window with text and image input, configurable thinking mode for step-by-step reasoning, and multilingual support across 140+ languages. The unquantized model fits on a single 80GB GPU.

For vision tasks, Gemma 4 31B supports image understanding with variable aspect ratios and resolutions, and can output structured bounding boxes for UI element detection, making it useful for document parsing and UI understanding. Compared to Gemma 3, it delivers stronger reasoning and multimodal performance. It is part of a four-size family alongside the 26B A4B MoE variant and two on-device models (E2B, E4B), with the 31B dense variant optimized for output quality and fine-tuning over inference speed.

Grok 4.7

Grok 4.7 is a proprietary model from SpaceXAI, released on September 21, 2026. It accepts text and images as input and returns text. It extends Grok 4.6 and is listed at the same API price.

Its Vision Evals scores are on the leaderboard. Running it in the Playground is not available yet, because the inference workflow is not ready.

Frequently Asked Questions

On Roboflow's Vision Evals, Grok 4.7 performed better. It scores higher on 5 of the six vision tasks and averages 71.9% (#22 of 54) against 67.0% (#31 of 54) for Gemma 4 31B. These scores measure vision capabilities only; either model may perform differently on work outside this benchmark's tasks.

No. On the Vision Evals Reasoning benchmark at low effort, Grok 4.7 leads with 64.2% against 50.8%. This is the widest gap between the two models across the benchmark's tasks.

Gemma 4 31B is cheaper to run. Across Roboflow's Vision Evals task mix it averaged $0.0012 per sample against $0.012. Actual costs depend on your image sizes, prompts, and output length.

Grok 4.7 is faster. Across Roboflow's Vision Evals it averaged 23.6s per inference against 28.8s. Latency varies with image size, prompt length, and provider load, so treat these as relative rather than guaranteed figures.