xAI has seven Grok models in the API right now. For OpenClaw, that list is noisier than it needs to be.

The lineup just shifted. Grok 4.3 went GA on April 30, 2026, replacing Grok 4.20 as the reasoning option at roughly 40% lower input cost and a 1M context window. For everyday cheap work, Grok 4.1 Fast is still the best default. The rest of the list is situational: Grok Code Fast when the task is mostly code, Grok 4.3 when the cheap models keep missing the point.

The quick answer

ModelInput/Output CostContextBest For
Grok 4.3$1.25 / $2.501MNew reasoning default (replaces 4.20)
Grok 4.1 Fast$0.20 / $0.502MDefault for cheap, high-volume tasks
Grok Code Fast$0.20 / $1.50256KCoding and file editing
Grok 4.20$2.00 / $6.002MUse 4.3 instead — same role, cheaper
Grok 4$3.00 / $15.00256KLegacy — skip
Grok 4 Fast$0.20 / $0.502MLegacy (use 4.1 Fast instead)
Grok 3$3.00 / $15.00131KLegacy

Most people should start with Grok 4.1 Fast for cost-sensitive work, then jump to Grok 4.3 when reasoning matters. Everything else is situational.

Grok 4.1 Fast — the default pick

Grok 4.1 Fast is what I’d point most people to. $0.20/M input, $0.50/M output, 2M token context window. You can load an entire monorepo into context for less than a dollar.

It handles tool calling well — shell commands, file reads, API calls come back syntactically correct. It’s fast enough for real-time chat and stays coherent across long sessions. At this price, you can run it against thousands of files without thinking about the bill.

Where it falls short: complex multi-step reasoning and code generation where correctness really matters. It also lacks real-time web search (that’s Grok 4’s thing). But for refactoring, quick tasks, and day-to-day coding, nothing in the xAI lineup matches it on cost.

Grok Code Fast — the coding specialist

Grok Code Fast was trained differently. xAI pre-trained it on a programming-heavy corpus and fine-tuned it on real pull requests, so it’s better at reading stack traces, generating clean diffs, and chaining shell commands than the general-purpose models.

$0.20/M input, $1.50/M output, 256K context. Output costs 3x more than 4.1 Fast, which adds up on code generation tasks where responses run long.

I reach for Code Fast over 4.1 Fast when I’m doing large refactors or debugging sessions where I need the model to actually understand what grep output means. If you’re mostly chatting with some light code mixed in, 4.1 Fast is fine and cheaper.

The real trade-off is context. Code Fast caps at 256K tokens. If your codebase fits, it’s the better coding model. If it doesn’t, 4.1 Fast with its 2M window is your only option.

Grok 4.3 — the new reasoning default

Grok 4.3 went GA on April 30, 2026, after a two-week SuperGrok Heavy beta. It is the reasoning model in the lineup, but priced like a workhorse: $1.25/M input, $2.50/M output, 1M context window. That is roughly 40% cheaper input and 60% cheaper output than the Grok 4.20 it replaces.

The headline change: reasoning is no longer a mode you toggle, it is always on. Every response goes through chain-of-thought before the model speaks. That sounds slow, but xAI gets ~207 tokens/second output, which is faster than Gemini 3.1 Flash and competitive with non-reasoning models.

It scores 53 on the Artificial Analysis Intelligence Index — well above the median of 35 for models in this price tier. Coding is its weakest axis: it trails Claude Opus 4.7 by about 14 points on SWE-bench Verified, so for hard refactors, Opus is still the right call. Where it shines is long-sequence agent simulation: on Vending-Bench it outperforms Opus 4.7 by ~1.26x, which matters for OpenClaw users running multi-step autonomous loops.

Other notes that matter for agent work:

  • Higher-context pricing kicks in past 200K tokens — under that threshold you pay the headline rate, above it the multiplier applies. Worth knowing before you dump a monorepo into context.
  • Prompt caching is $0.20/M for repeat input — if you reuse system prompts, the effective cost drops further.
  • Native video, PDF, PPTX, and XLSX are now first-class inputs/outputs. Mostly relevant if you’re using OpenClaw beyond pure coding.

This is the model you reach for when 4.1 Fast can’t figure it out. Hard debugging across multiple files, architecture reviews, agentic loops where the model needs to hold a lot of context and actually reason through trade-offs. If you’ve been paying $15/M output for Claude Opus on tasks that don’t strictly need it, swap in Grok 4.3 first and see how often it lands.

Grok 4.20 — superseded by 4.3

Grok 4.20 was the reasoning option from March 18 to April 30. Same role as 4.3, more expensive ($2/$6 vs $1.25/$2.50), smaller intelligence-index score (48 vs 53). There’s no reason to start a new project on it. If you’ve already configured it in OpenClaw, swap the model id from grok-4.20-beta-reasoning to grok-4-3 and you’ll pay less for better output.

Grok 4 — skip it

Grok 4 is the legacy premium option at $3/$15 per million tokens. Its one unique feature was real-time web search baked into the model. Two things killed it: OpenClaw already has tool-calling for web searches, and Grok 4.3 does better reasoning for less than half the price with 4x the context (1M vs 256K). There is no use case where Grok 4 is the right call in 2026.

Setup in OpenClaw

Running through haimaker.ai

All Grok models are also available through haimaker.ai with a single API key. If you’re already using haimaker for other providers, you can access Grok models without a separate xAI account:

{
  "models": {
    "providers": {
      "haimaker": {
        "baseUrl": "https://api.haimaker.ai/v1",
        "apiKey": "your-haimaker-api-key",
        "api": "openai-completions"
      }
    }
  }
}

This gives you Grok alongside Claude, GPT, Gemini, and dozens of open-source models through one provider.

Getting any Grok model running takes about two minutes.

1. Get your xAI API key

Sign up at console.x.ai. New accounts get $25 in free credits, plus $150/month if you opt into the data sharing program.

2. Add xAI as a provider

Open ~/.openclaw/openclaw.json and add xAI to your providers:

{
  "models": {
    "providers": {
      "xai": {
        "baseUrl": "https://api.x.ai/v1",
        "apiKey": "your-xai-api-key",
        "api": "openai-completions"
      }
    }
  }
}

3. Add models to the allowlist

In the same file, add the models you want to use:

{
  "agents": {
    "defaults": {
      "models": {
        "xai/grok-4-3": {},
        "xai/grok-4-1-fast": {},
        "xai/grok-code-fast": {}
      }
    }
  }
}

4. Apply the config

Run openclaw gateway config.apply and switch models with /model during a session.

What I’d do

Set Grok 4.1 Fast as your default for cheap, high-volume work. Swap to Grok Code Fast when you’re heads-down coding and want the model to actually understand your toolchain. Bring in Grok 4.3 when something is genuinely hard and the cheaper models keep getting it wrong — it is significantly better than 4.20 and meaningfully cheaper.

Ignore Grok 4, Grok 4 Fast, and Grok 3. They cost more and do less than the newer models.