xAI LLM API pricing
Every model xAI serves, with its pricing per 1M tokens and the exact model ID to copy. Sorted cheapest input first. Verified against LiteLLM and OpenRouter daily.
Models served
40
on this provider
Cheapest input
$0.20
per 1M tokens
Cheapest output
$0.50
per 1M tokens
Max context
2M
tokens
| Model ID | |||||
|---|---|---|---|---|---|
| Grok 4 Fast Reasoning | xAI | 2M | $0.20 | $0.50 | xai/grok-4-fast-reasoning |
| Grok 4 Fast Non Reasoning | xAI | 2M | $0.20 | $0.50 | xai/grok-4-fast-non-reasoning |
| Grok 4.1 Fast | xAI | 2M | $0.20 | $0.50 | xai/grok-4-1-fast |
| Grok 4.1 Fast Reasoning | xAI | 2M | $0.20 | $0.50 | xai/grok-4-1-fast-reasoning |
| Grok 4.1 Fast Reasoning Latest | xAI | 2M | $0.20 | $0.50 | xai/grok-4-1-fast-reasoning-latest |
| Grok 4.1 Fast Non Reasoning | xAI | 2M | $0.20 | $0.50 | xai/grok-4-1-fast-non-reasoning |
| Grok 4.1 Fast Non Reasoning Latest | xAI | 2M | $0.20 | $0.50 | xai/grok-4-1-fast-non-reasoning-latest |
| Grok Code Fast 1 0825 | xAI | 256K | $0.20 | $1.50 | xai/grok-code-fast-1-0825 |
| Grok Code Fast | xAI | 256K | $0.20 | $1.50 | xai/grok-code-fast |
| Grok Code Fast 1 | xAI | 256K | $0.20 | $1.50 | xai/grok-code-fast-1 |
| Grok 3 Mini | xAI | 131K | $0.30 | $0.50 | xai/grok-3-mini |
| Grok 3 Mini Beta | xAI | 131K | $0.30 | $0.50 | xai/grok-3-mini-beta |
| Grok 3 Mini Latest | xAI | 131K | $0.30 | $0.50 | xai/grok-3-mini-latest |
| Grok 3 Mini Fast | xAI | 131K | $0.60 | $4.00 | xai/grok-3-mini-fast |
| Grok 3 Mini Fast Beta | xAI | 131K | $0.60 | $4.00 | xai/grok-3-mini-fast-beta |
| Grok 3 Mini Fast Latest | xAI | 131K | $0.60 | $4.00 | xai/grok-3-mini-fast-latest |
| Grok 4.3 Latest | xAI | 1M | $1.25 | $2.50 | xai/grok-4.3-latest |
| Grok 4.3 | xAI | 1M | $1.25 | $2.50 | xai/grok-4.3 |
| Grok 4.5 | xAI | 500K | $2.00 | $6.00 | xai/grok-4.5 |
| Grok 4.5 Latest | xAI | 500K | $2.00 | $6.00 | xai/grok-4.5-latest |
| Grok 2 | xAI | 131K | $2.00 | $10.00 | xai/grok-2 |
| Grok 2 1212 | xAI | 131K | $2.00 | $10.00 | xai/grok-2-1212 |
| Grok 2 Latest | xAI | 131K | $2.00 | $10.00 | xai/grok-2-latest |
| Grok 2 Vision | xAI | 33K | $2.00 | $10.00 | xai/grok-2-vision |
| Grok 2 Vision Latest | xAI | 33K | $2.00 | $10.00 | xai/grok-2-vision-latest |
| Grok 4 20 Multi Agent Beta 0309 | xAI | 2M | $2.00 | $6.00 | xai/grok-4.20-multi-agent-beta-0309 |
| Grok 4 20 Beta 0309 Reasoning | xAI | 2M | $2.00 | $6.00 | xai/grok-4.20-beta-0309-reasoning |
| Grok 4 20 0309 Reasoning | xAI | 2M | $2.00 | $6.00 | xai/grok-4.20-0309-reasoning |
| Grok 4 20 Beta 0309 Non Reasoning | xAI | 2M | $2.00 | $6.00 | xai/grok-4.20-beta-0309-non-reasoning |
| Grok 2 Vision 1212 | xAI | 33K | $2.00 | $10.00 | xai/grok-2-vision-1212 |
| Grok 3 | xAI | 131K | $3.00 | $15.00 | xai/grok-3 |
| Grok 3 Beta | xAI | 131K | $3.00 | $15.00 | xai/grok-3-beta |
| Grok 3 Latest | xAI | 131K | $3.00 | $15.00 | xai/grok-3-latest |
| Grok 4 | xAI | 256K | $3.00 | $15.00 | xai/grok-4 |
| Grok 4 0709 | xAI | 256K | $3.00 | $15.00 | xai/grok-4-0709 |
| Grok 4 Latest | xAI | 256K | $3.00 | $15.00 | xai/grok-4-latest |
| Grok 3 Fast Beta | xAI | 131K | $5.00 | $25.00 | xai/grok-3-fast-beta |
| Grok 3 Fast Latest | xAI | 131K | $5.00 | $25.00 | xai/grok-3-fast-latest |
| Grok Vision Beta | xAI | 8K | $5.00 | $15.00 | xai/grok-vision-beta |
| Grok Beta | xAI | 131K | $5.00 | $15.00 | xai/grok-beta |
Pricing verified against LiteLLM + OpenRouter + provider pages · refreshed daily
Every weekday
AI moves fast. Here's your debrief.
News, analysis, tools, and more.
For people who build with AI