grok-4 by xai - AI Model Details, Pricing, and Performance Metrics

xai
grok-4
xai

grok-4

completions
byxai

Grok 4 is the latest and greatest flagship model, offering unparalleled performance in natural language, math and reasoning - the perfect jack of all trades.

Released
Jul 9, 2025
Knowledge
Dec 31, 2024
License
Proprietary
Context
256K
Input
$3 / 1M tokens
Output
$15 / 1M tokens
Cached
$0.75 / 1M tokens
Capabilities: tools
Accepts: text
Returns: text

Access grok-4 through LangDB AI Gateway

Recommended

Integrate with xai's grok-4 and 250+ other models through a unified API. Monitor usage, control costs, and enhance security.

Unified API
Cost Optimization
Enterprise Security
Get Started Now

Free tier available • No credit card required

Instant Setup
99.9% Uptime
10,000+Monthly Requests
Request Volume
Daily API requests
2
Performance (TPS)
Tokens per second
76.44 tokens/s

Benchmark Tests

View Other Benchmarks
AIME
94.3
Mathematics
AA Coding Index
63.8
Programming
AAII
65.3
General
AA Math Index
96.7
Mathematics
GPQA
87.6
STEM (Physics, Chemistry, Biology)
HLE
23.9
General Knowledge
LiveCodeBench
81.9
Programming
MATH-500
99.0
Mathematics
MMLU-Pro
86.6
General Knowledge
SciCode
45.7
Scientific

Code Examples

Integration samples and API usage