xai

Grok Code Fast 1

Grok Code Fast 1 is xAI's economical reasoning model focused on agentic coding tasks. It is a text-only model with a 256,000 token context window and a 10,000 token maximum output per request. At $0.20/M input and $1.50/M output, it is one of the cheapest options in our dataset by output cost. In our 12-test general-purpose benchmark suite, it ranks 38th out of 52 active models — below the field median. Its provider description emphasizes speed and coding specialization, and our strongest result for it is agentic planning (5/5, tied for 1st with 14 other models out of 54). Like other coding-specialized models, its general-purpose benchmark rank reflects test-suite composition more than coding capability.

Performance

In our 12-test general-purpose benchmark suite, Grok Code Fast 1 ranks 38th out of 52 active models. Its strongest result is agentic planning (5/5, tied for 1st with 14 other models out of 54). Classification scored 4/5 (tied for 1st with 29 others out of 53), and structured output and tool calling both came in at 4/5. Faithfulness scored 4/5 (rank 34 of 55). Weaker areas: constrained rewriting (3/5, rank 31 of 53), strategic analysis (3/5, rank 36 of 54), creative problem solving (3/5, rank 30 of 54), and multilingual (4/5, but rank 36 of 55). Safety calibration scored 2/5 at the field median. These results reflect general-purpose testing; code-specific performance may differ.

Pricing

Grok Code Fast 1 costs $0.20 per million input tokens and $1.50 per million output tokens. At 10 million output tokens per month, that is $15. At 100 million tokens, $150. This makes it one of the lowest-priced options in our catalog by output cost — only a handful of models cost less per output million. The tradeoff is a 10,000 token max output limit per request, which constrains it for generating large code artifacts in a single pass. Reasoning tokens count toward token consumption when reasoning parameters are enabled. Teams running high-volume agentic coding pipelines will find the $0.20/$1.50 pricing highly efficient.

xai

Grok Code Fast 1

Overall
3.67/5Strong

Benchmark Scores

Faithfulness
4/5
Long Context
4/5
Multilingual
4/5
Tool Calling
4/5
Classification
4/5
Agentic Planning
5/5
Structured Output
4/5
Safety Calibration
2/5
Strategic Analysis
3/5
Persona Consistency
4/5
Constrained Rewriting
3/5
Creative Problem Solving
3/5

External Benchmarks

SWE-bench Verified
N/A
MATH Level 5
N/A
AIME 2025
N/A

Pricing

Input

$0.200/MTok

Output

$1.50/MTok

Context Window256K

modelpicker.net

Real-World Costs

iChat response<$0.001
iBlog post$0.0031
iDocument batch$0.079
iPipeline run$0.790

Pricing vs Performance

Output cost per million tokens (log scale) vs average score across our 12 internal benchmarks

This modelOther models

Try It

from openai import OpenAI

client = OpenAI(
    base_url="https://openrouter.ai/api/v1",
    api_key="YOUR_OPENROUTER_KEY",
)

response = client.chat.completions.create(
    model="x-ai/grok-code-fast-1",
    messages=[
        {"role": "user", "content": "Hello, Grok Code Fast 1!"}
    ],
)

print(response.choices[0].message.content)

Recommendation

Grok Code Fast 1 is positioned for cost-sensitive agentic coding pipelines where the 5/5 agentic planning score and very low $1.50/M output pricing are the primary decision factors. Teams running large volumes of coding agents, code review automation, or debugging workflows will benefit from the low output cost. Note the 10,000 token max output limit per request — this restricts generation of large files in one pass. For general-purpose text tasks, classification, or strategic analysis, models ranking higher on our overall benchmarks will serve better. Reasoning tokens should be factored into cost estimates when the reasoning parameter is enabled.

How We Test

We test every model against our 12-benchmark suite covering tool calling, agentic planning, creative problem solving, safety calibration, and more. Each test is scored 1–5 by an LLM judge. Read our full methodology.

Frequently Asked Questions