HCODX/Grok Cost Calculator
xAI · Grok 4 family · Live 2026 pricing

Grok Cost Calculator: estimate xAI Grok API spend

Estimate xAI Grok API spend across Grok 4, Grok 4.3, Grok 4.20, and Grok 4.1 Fast. Enter input/output token counts (or paste a prompt) and your monthly volume — get per-call, per-day, per-month, and per-year cost in USD, EUR, or GBP.

Prompt text (optional)0 tokens
Cost breakdown
Calculator options
3,000calls / month · ~100 / day
Count tokens precisely
Input tokens
0
Output tokens
0
Per call
Status
Ready
Pricing reference

Grok API pricing reference (2026)

Current per-million-token rates published on the provider's website. Toggle "Edit rates" above if you have a negotiated rate or want to model future pricing.

ModelInput / 1MOutput / 1MContext
Grok 4
xAI
$3.00$15.00256K
Grok 4.3
xAI
$1.25$2.501M
Grok 4.20
xAI
$2.00$6.00256K
Grok 4.1 Fast
xAI
$0.20$0.502M
Use cases

What you'll use this for

LLM costs scale fast. A quick estimate before you ship saves real money in production.

Budget planning

Project monthly and annual Grok API spend before you ship. Catch surprises before billing does.

Comparing tiers

Cheapest Grok 4.1 Fast vs flagship Grok 4 — see when the cheaper tier still hits your quality bar.

Cost optimization

Toggle Advanced rates to model caching discounts, batch tiers, or negotiated enterprise pricing.

Pricing transparency

Show stakeholders concrete numbers for 'what does Grok cost us?' — no vendor pitch deck required.

Step by step

How to estimate Grok cost

1

Pick a model & enter tokens

Either paste a real prompt (auto-counted) or type input tokens directly. Set expected output tokens for the model's reply.

2

Set monthly call volume

Drag the slider. The tool projects per-call, per-day, per-month and per-year cost in your selected currency.

3

Compare or override

Switch the model dropdown to compare tiers. Toggle Advanced to override rates if you have a custom contract.

FAQ

Frequently asked questions

From xAI's published API pricing pages as of 2026. The rates shown are list prices for the standard real-time endpoint. xAI offers a Live Search add-on and various enterprise tiers that may differ — always verify on the official pricing page before procurement decisions.

Grok 4.1 Fast is xAI's price/speed tier — distilled from Grok 4 and optimized for throughput. At $0.20 input and $0.50 output per million tokens it competes with GPT-4o mini and Haiku 4.5 on cost while keeping a 2M-token context window. Use it for retrieval, agents, and batch workloads.

xAI offers prompt caching that reduces cached-input rates by roughly 75–90% on subsequent calls. There is no separate Batch API like OpenAI's 50%-off tier yet, but high-volume enterprise customers can negotiate. This calculator uses the standard list price — adjust the Advanced rate editor if your contract differs.

No — the EUR and GBP rates use a fixed approximate exchange rate baked into the tool (EUR ≈ 0.92, GBP ≈ 0.79). For accurate procurement figures use your bank's mid-market rate at the time of billing. xAI bills in USD.

About

About Grok pricing

xAI's Grok pricing follows a familiar tiered model: a top-tier reasoning flagship, a mid-tier general purpose model, a creative variant, and a fast/cheap inference tier. The whole family bills per million tokens, separated into input and output rates.

Per-tier breakdown

  • Grok 4 — $3.00 input / $15.00 output per M. Comparable to Claude Sonnet 4.6 on input, more expensive on output. Use for reasoning, complex agents, and tool use where capability matters most.
  • Grok 4.3 — $1.25 input / $2.50 output per M. Mid-tier sweet spot with a 1M-token context. Great for long-document RAG.
  • Grok 4.20 — $2.00 input / $6.00 output per M. Tuned for creative writing, personas, and brand voice work.
  • Grok 4.1 Fast — $0.20 input / $0.50 output per M. The cheapest tier — usually 10× cheaper than Grok 4 — with a 2M-token context built for batch and agent loops.

How costs scale

Output tokens dominate the bill for chat applications: most replies are 5–20× longer than the user message. For Grok 4 at standard rates, a 500-token reply to a 200-token prompt costs about $0.008 — multiply by your call volume to see the monthly impact.

When Grok makes sense

Grok shines on creative writing, real-time data via Live Search, and high-throughput cheap inference (Grok 4.1 Fast). For pure code or hard math, GPT-5 and Claude Opus 4.7 still lead per dollar — but the gap is narrowing, and the 1M+ context windows of Grok 4.3 and Grok 4.1 Fast are competitive with Gemini's offerings.

Related

Related tools