xAI: Grok-4
Grok-4 is a reasoning model from xAI released on Jul 9, 2024. It reads text and images and writes text, with a 256K token context window and up to 128K tokens per reply.
Show moreShow less
It costs $3 per million input tokens and $15 per million output tokens. Cached input bills at $0.75, 75% less than fresh input.
It supports tool calling and prompt caching.
5 providers serve it, including DevPass (LLM Gateway), FastRouter and Helicone.
- Modalities
- In / out price
- $3 / $15 per 1M
- Context
- 256K
- Max output
- 128K
- Released
- Jul 9, 2024
- Knowledge cutoff
- n/a
- Tool calling
- Structured output
- Reasoning
- Prompt caching
- Open weights
- Free to use
Grok-4 pricing
USD, as listed on Oct 15, 2026. Most bills are input heavy, so the cached input rate matters as much as the headline price.
| Input | $3 / 1M tokens | |
|---|---|---|
| Output | $15 / 1M tokens | |
| Cached input (read) | $0.75 / 1M tokens | 75% off input |
Grok-4 providers
5 providers serve it, including DevPass (LLM Gateway), FastRouter and Helicone. Each host sets its own price and limits, so the cheapest one is not always the one with the longest context.
| Provider | Input /M | Output /M | Cache read /M | Context | Max output |
|---|---|---|---|---|---|
| DevPass (LLM Gateway) | $3 | $15 | $0.75 | 256K | 256K |
| FastRouter | $3 | $15 | $0.75 | 256K | 64K |
| Helicone | $3 | $15 | $0.75 | 256K | 256K |
| LLM Gateway | $3 | $15 | $0.75 | 256K | 256K |
| Poe | $3 | $15 | $0.75 | 256K | 128K |
What Grok-4 costs per month
Pick a workload close to yours or type your own volumes.
Supported request parameters
What you can set when you call Grok-4 through an OpenAI compatible API.
- Tools
tools - Reasoning
reasoning
Alternatives to Grok-4
Models that take the same inputs and call tools, closest in price, cheaper ones first.
- Index 43.6
Reads text, images and video. Tool calling, structured output, reasoning. Served by 72 providers.
by moonshotaiJul 16, 20261.05M context$3/M input tokens$15/M output tokens72 providers
- 1M context
Reads text, images and files. Tool calling, structured output, reasoning. Served by 48 providers.
by anthropicFeb 5, 2026$3/M input tokens$15/M output tokens48 providers
- 200K context
Reads text, images and files. Tool calling, structured output, reasoning. Served by 33 providers.
by anthropicJan 15, 2025$3/M input tokens$15/M output tokens33 providers
- 262K context
Reads text and images. Tool calling, structured output, reasoning. Served by 22 providers.
by thinkingmachinesJul 15, 2026$3.74/M input tokens$9.36/M output tokens22 providers
- Index 42.1
Reads text, images and files. Tool calling, structured output, reasoning. Served by 38 providers.
by openaiJul 9, 20261.05M context$2/M input tokens$12/M output tokens38 providers
- Index 29.7
Reads text, images, files, audio and video. Tool calling, structured output, reasoning. Served by 5 providers.
by googleFeb 19, 20261.05M context$2/M input tokens$12/M output tokens5 providers
More from xAI
- 1K context
Generates video from text, images and files. Served by 2 providers.
by x-aiOct 1, 20262 providers
- Index 46.5
Reads text, images and files. Tool calling, structured output, reasoning. Served by 22 providers.
by x-aiSep 16, 2026500K context$2/M input tokens$6/M output tokens22 providers
- 500K context
Reads text, images and files. Tool calling, structured output, reasoning. Served by 29 providers.
by x-aiAug 10, 2026$2/M input tokens$6/M output tokens29 providers
- 66K context
Generates images from text and images. Served by 3 providers.
by x-aiAug 7, 2026$0/M input tokens$0/M output tokens3 providers
Grok Voice STT 1.0
Transcription15K contextTurns speech into text.
by x-aiAug 4, 2026
Grok Voice TTS 1.0
Speech15K contextTurns text into spoken audio.
by x-aiJul 31, 2026
Grok-4 questions
How much does the Grok-4 API cost?
$3 per million input tokens and $15 per million output tokens, with cached input at $0.75. The estimator on this page turns that into a monthly bill for your own workload.
What is the context window of Grok-4?
256,000 tokens of input, and it can write up to 128,000 tokens in one reply. As a rough guide, a million tokens is around 750,000 English words.
Which providers serve Grok-4?
5 providers serve it, including DevPass (LLM Gateway), FastRouter and Helicone. Prices differ by host, so the Providers table on this page lists each one with its input and output price.
Does Grok-4 support tool calling?
Yes. It accepts tool definitions, which is what an agent needs to call your APIs.
Is Grok-4 open source?
No. xAI serves it through an API only, so you cannot download the weights or host it yourself.
When was Grok-4 released?
Jul 9, 2024.
Catalog data from models.dev (MIT licensed), refreshed daily, last on Oct 15, 2026. The summary is written from these facts.
Building on Grok-4?
I test your real tasks on it and the two closest alternatives, then ship the agent on whichever wins on cost and accuracy.
Book Meeting