Grok Code Fast API pricing
Published on-demand rates for xAI's xai/grok-code-fast, captured 2026-09-21 from public pricing data and committed to our archive. Context window 256k tokens; first observed in our archive 2025-09-01.
| Meter | USD per 1M tokens |
|---|---|
| Input | $1.00 |
| Output | $2.00 |
| Cached input | $0.200 |
Standard on-demand rates. Excludes batch endpoints and negotiated pricing; confirm on xAI's pricing page before committing.
What it costs on a real workload
Per 1M tokens processed, at the rates above. How the four profiles are defined.
| Profile | In / out mix | Cached share | Cost |
|---|---|---|---|
| Retrieval | 800k / 200k | 70% | $0.752 |
| Chat | 500k / 500k | 30% | $1.38 |
| Content | 200k / 800k | 20% | $1.77 |
| Agent | 900k / 100k | 85% | $0.488 |
Observed rate history
| Observed | Input | Output | Cached input | |
|---|---|---|---|---|
| 2025-09-01 | $0.200 | $1.50 | $0.020 | entered our archive |
| 2026-08-13 | $1.00 | $2.00 | $0.200 | repricing observed |
Dates are when we observed the rate in our own snapshots, which can lag the provider's announcement. Rates per 1M tokens.
What the record shows
We have observed one change to Grok Code Fast's rates since it entered our archive on 2025-09-01. In the most recent, on 2026-08-13, xAI raised the output rate by 33%, from $1.50 to $2.00 per 1M.
Against the 40 models we price, it is the 18th cheapest for retrieval-shaped work, which reads a great deal and writes little, and the 18th cheapest for content-shaped work, which does the reverse. The two are close, so it holds its position whichever way your workload leans.
It charges 2.0 times more for output than for input, against a median of 5.0 times across the set. That is narrower than most, so it punishes long answers less than the typical model does.
Inside xAI's own lineup it is the cheapest of the 3 models we track on this workload, which makes it the floor to measure the rest of the house against before looking outside it at all.
27 of the 40 models we price offer a larger context window, and 2 match it exactly. Context is a capability limit rather than a cost one: paying more buys no extra room unless the larger window is what you are paying for.
Cached input reads at $0.200 against a standard input rate of $1.00, a 80% discount on the part of your prompt that repeats.
It accepts image input, but xAI publishes no rule for how images become tokens, so we will not price a scanned page on it. That is a gap in the provider's documentation rather than a limit of the model, and it is the reason this model is excluded from image estimates in our estimator instead of being given a plausible figure.
Its 256k token context window holds roughly 192,000 words of English text in a single request. A workload that does not fit cannot run here at any price, which is a capability limit rather than a cost one.
Priced near this one
Closest to Grok Code Fast on a retrieval workload, cheaper and more expensive alike. Cost only; we publish no quality score.
| Model | Provider | Input | Output | vs Grok Code Fast |
|---|---|---|---|---|
| Devstral | Mistral | $0.400 | $2.00 | 4% less |
| Grok 4.3 | xAI | $1.25 | $2.50 | 21% more |
| Gemini 3.5 Flash Lite | $0.300 | $2.50 | 22% less | |
| Gemini 3.8 Flash | $0.750 | $3.75 | 29% more |
Retrieval profile: 800k in, 200k out, 70% cached where offered.
No affiliate or referral arrangements: the console link carries no parameters and nothing on this page is paid placement. Grok Code Fast is a trademark of its owner; LLMPrice.io is independent and unaffiliated.