← Back to All Providers

xAI API Pricing

xAI API pricing for all 6 models, updated March 2026. Compare input and output token costs per 1M tokens across the full xAI model range.

Cheapest model: Grok 4 Fast at $0.20/1M input tokens

tokens
tokens
Model
Provider
Input / 1M
Output / 1M
Est. Input Cost
Est. Output Cost
Grok 4 Fast2,000,000 ctx
xAI$0.20$0.50$0.2000$0.5000
Grok 4.1 Fast2,000,000 ctx
xAI$0.20$0.50$0.2000$0.5000
Grok 3 Mini131,000 ctx
xAI$0.30$0.50$0.3000$0.5000
Grok 4.20 Beta2,000,000 ctx
xAI$2.00$6.00$2.0000$6.0000
Grok 4256,000 ctx
xAI$3.00$15.00$3.0000$15.0000
Grok 3131,000 ctx
xAI$3.00$15.00$3.0000$15.0000
Showing 6 models
Prices updated daily. Last update: 3/16/2026

About xAI API Pricing

xAI offers 6 API models tracked on UsagePricing. All prices shown are standard pay-as-you-go rates per 1 million tokens — input tokens (your prompt) and output tokens (the model's response) are billed separately. Prices are reviewed daily and reflect the latest published rates from xAI.