XAI API PRICING

xAI Grok token cost calculator.

Estimate Grok API spend from current official input, cached-input, output, context-window, and regional price scopes.

Models
5
Rate cards
7
Input range
$1$4
Output range
$2$12
Cache-priced cards
7
Verified
2026-08-16
XAI WORKLOAD

Model the calls you actually make.

Enter monthly workload, tokens, and quality pass rates. The calculator resolves eligible price bands, then shows cost per accepted answer and the candidate break-even pass rate.

Estimated monthly API spend · xAI
Grok 4.6Before · Standard · below 200K prompt: $2 input · $0.5 cache read · $6 output / 1MAfter · Standard · below 200K prompt: $2 input · $0.5 cache read · $6 output / 1MxAI direct API · price bands selected automatically from input size
Before$90.00
After$58.88
Potential saving: $31.12 (34.6%)
QUALITY-ADJUSTED COST
Before / accepted answer$0.010090% pass assumption
After / accepted answer$0.006985% pass assumption

Candidate break-even: 58.9% pass rate. Your scenario assumes 85%.

Warm cache-read scenario, not general ROI. It excludes cache writes/storage, tools, regional uplifts, retries, and quality failures. A dash means no published cache-read rate.

xAI model pricing
NEXT STEPValidate the 30.7% accepted-answer advantage.

The estimate is not a saving until the same workload still passes its quality bar. Compare a supported recipe in the lab, or use the evidence library to design a provider-specific test.

A published cache-read discount is not a guaranteed cache hit. Model realistic warm-cache shares and measure actual provider usage before treating a scenario as savings.

DATED RATE CARDS

xAI prices with their scope intact.

Rates are USD per one million tokens. Future and transitional cards remain labeled with their effective dates instead of silently replacing today’s tier.

Showing 7 of 52 rate cards

Official provider API rate cards, USD per one million tokens
Provider / modelPrice scopeInput
USD / 1M
Cache read
USD / 1M
Output
USD / 1M
ContextSource
xAIGrok 4.20 Reasoninggrok-4.20-0309-reasoningStandard · below 200K promptxAI direct API$1.25$0.2$2.501MOfficial ↗
xAIGrok 4.3grok-4.3Standard · 200K+ promptxAI direct API$2.50$0.4$51MOfficial ↗
xAIGrok 4.3grok-4.3Standard · below 200K promptxAI direct API$1.25$0.2$2.501MOfficial ↗
xAIGrok 4.5grok-4.5Standard · below 200K promptxAI direct API$2$0.3$6500KOfficial ↗
xAIGrok 4.6grok-4.6Standard · 200K+ promptxAI direct API$4$1$12500KOfficial ↗
xAIGrok 4.6grok-4.6Standard · below 200K promptxAI direct API$2$0.5$6500KOfficial ↗
xAIGrok Build 0.1grok-build-0.1Standard · below 200K promptxAI direct API$1$0.2$2256KOfficial ↗

Rates in USD per 1M tokens

USD per 1M tokens. Snapshot verified 2026-08-16. Cache writes, cache storage, tools, regions, and provider-specific thresholds may be billed separately.

A missing cache rate is shown as “—”, never treated as free. Consumer chat-plan quotas are not API prices.

BILLING CAVEAT

What to verify before shipping

A published cache-read discount is not a guaranteed cache hit. Model realistic warm-cache shares and measure actual provider usage before treating a scenario as savings.

MEASUREMENT RULE

Price accepted answers, not token deltas

Count retries, fallbacks, tool calls, latency failures, and answers rejected by the quality rubric. A lower estimated token bill is useful only when the workload still succeeds.

Open the controlled A/B lab
QUESTIONS

Before you trust the estimate.

How current are the xAI API prices?

This page uses TokenGauge’s 2026-08-16 official-source snapshot. Follow the linked provider pages before making a production commitment because prices can change.

Does this calculator include every xAI charge?

No. It models input, output, and a warm cache-read share. Cache writes or storage, tools, retries, regional uplifts, taxes, batch modes, and quality failures can change the final invoice.

Are consumer chat subscriptions included?

No. ChatGPT, Claude, Gemini, Grok, Kimi, and other consumer-plan quotas are separate from provider API token billing.