xAI's current Grok API model lineup
xAI prices three models for API access. Grok 4.5 is the current flagship, priced at $2 input / $6 output per million tokens, and is the choice when you need xAI's strongest available capability. Grok 4.3 sits below it at $1.25 / $2.50 and remains genuinely relevant rather than a leftover previous-generation model. See the context-window note below. Grok 4.1 Fast is the budget and high-volume tier at $0.20 / $0.50, built for speed and cost efficiency on simpler or higher-volume requests where the flagship's extra capability wouldn't change the output.
Grok 4.5's cached-input rate and tiered pricing
Grok 4.5 has two pricing details worth knowing beyond the headline rate. First, a cached-input rate: prompt tokens that repeat a prefix xAI has already processed recently bill at $0.50 per million tokens instead of the standard $2, a substantial discount for any workload that resends a stable system prompt or reference context across calls. Second, tiered pricing by prompt length: the $2 / $6 rate holds up to 200,000 tokens of prompt, and steps up to $4 / $12 above that threshold. Both details change the effective cost of a given workload well beyond what the sticker rate suggests, so factor them in specifically rather than budgeting off the headline number alone.
Why Grok 4.3 isn't just "the old model"
It's tempting to assume a newer flagship makes the previous generation obsolete, but Grok 4.3 has a real, specific advantage over Grok 4.5: a 1-million-token context window, versus Grok 4.5's 500,000 tokens at standard pricing. For a task that genuinely needs to hold a very large document, a big codebase, or an extensive conversation history in context at once, Grok 4.3's window covers double what Grok 4.5 can take before you'd need to either trim the prompt or move into Grok 4.5's higher-priced extended tier. That makes Grok 4.3 the right default specifically for long-context workloads, independent of which model is "newer." Check your actual prompt size against both windows before defaulting to the flagship.
How Grok's pricing structure works
All three Grok models bill input and output tokens separately, with output priced higher than input across the lineup, consistent with every other provider covered here, reflecting that generating tokens costs more than reading them. The three-tier spread from Fast up to 4.5 gives you a reasonably clean routing decision: Fast for volume, 4.3 for long-context work, 4.5 for everything else that needs the flagship's capability. Because Grok 4.5 adds cached-input and tiered-length pricing on top of that base structure, it's worth modeling your actual traffic shape (prompt length, and how often a prefix repeats) rather than comparing sticker rates alone once Grok 4.5 is in the mix.
Cutting your Grok API bill
Route high-volume or simple requests to Grok 4.1 Fast by default, and reserve Grok 4.5 for requests that need its capability specifically. If you're on Grok 4.5, structure prompts so a stable, repeated block comes first and stays identical across calls to capture the $0.50 cached-input rate, and keep prompts under the 200,000-token threshold where your task allows it to avoid the tiered step-up to $4 / $12. If your workload is built around very large context specifically, compare Grok 4.3's 1M-token window directly against Grok 4.5's extended tier, the older model can be both cheaper and roomier for that particular shape of traffic. Beyond model and tier choice, the usual fundamentals apply: cap max output tokens, keep system prompts lean, and reuse repeated context across calls where your integration supports it.
A worked example on Grok 4.5
At Grok 4.5's standard rate ($2 input / $6 output per million tokens), a 1,000-token prompt with a 500-token answer costs 1,000 ÷ 1,000,000 × $2 = $0.002 for input, plus 500 ÷ 1,000,000 × $6 = $0.003 for output, $0.005 per call, or $500 a month at 100,000 calls. Now suppose 800 of those 1,000 input tokens are a stable prefix that hits the cache: those 800 tokens drop to the $0.50 cached-input rate while only the remaining 200 fresh tokens bill at $2, cutting the input side of the bill by roughly 80% before touching the output side at all. Switch the same volume to Grok 4.1 Fast instead and the bill drops further still, in proportion to Fast's lower rate on both input and output, worth checking directly if your task doesn't specifically need Grok 4.5's extra capability.
Compare Grok against Anthropic's Claude API pricing, Google's Gemini API pricing, or OpenAI's GPT API pricing.