xAI's budget coding model: agentic-loop pricing for code tasks that don't need a frontier brain.
Coding agents burn tokens — every loop re-reads files, re-runs context, retries. Grok Code Fast 1 is priced for that reality: $0.20 input and $1.50 output per 1M tokens means an agent can iterate twenty times for less than one Sonnet 4.6 pass. It's the model you point at high-volume, low-stakes code work.
It shares the 256K window with flagship Grok 4.20, so repo-scale context isn't the sacrifice — reasoning depth is.
Competent code generation, edits, and explanations across mainstream languages at high speed. The use case that fits best: scripted or agentic pipelines where the task is well-defined and a retry costs fractions of a cent.
The honest weakness: hard problems. Subtle bugs, architecture, and multi-file refactors with hidden dependencies want Sonnet 4.6 or better. For pure IDE fill-in-the-middle completion, Codestral is the more specialized (and cheaper-output) tool.
| Model | Input / 1M | Output / 1M | Context |
|---|---|---|---|
| Grok Code Fast 1 | $0.20 | $1.50 | 256K |
| Codestral | $0.30 | $0.90 | 256K |
| Grok 4.20 | $2 | $6 | 256K |
| Claude Sonnet 4.6 | $3 | $15 | 200K (1M β) |
| GPT-5.4 | $2.50 | $15 | 272K |
The direct rival is Codestral: cheaper output and FIM completion, but less agentic framing. The frontier coding models cost 10× more and are worth it when correctness is expensive. Code Fast earns its keep as the volume layer under a smarter model.