# xAI: grok-4.20

grok-4.20 is a language model from xAI. It reads and writes text.

- **Model id:** `opencheap/grok-4.20`
- **Price per 1M tokens:** $1.25 input / $2.50 output
- **Cached input:** $0.20 per 1M tokens
- **Context:** 2M tokens, 1.8M max output

## Providers

3 providers. Prices are per 1M tokens. As of 2026-12-04 12:06 UTC.

| Provider | Input price | Cache price | Output price | Latency | Speed | Uptime | Context | Max output |
| --- | --- | --- | --- | --- | --- | --- | --- | --- |
| NanoGPT · quantization unknown | $1.25 | $0.20 | $2.50 | — | — | — | 2M | 131K |
| xAI · Route 1 | $1.31 | $0.21 | $2.63 | 0.67 s | 79 tok/s | 100 % | 2M | 1.8M |
| xAI · Route 2 | $1.31 | $0.21 | $2.63 | 0.57 s | 69 tok/s | 100 % | 2M | 1.8M |
| xAI · Route 3 | $2.63 | $0.42 | $5.25 | — | — | — | 2M | 1.8M |
| xAI · Route 4 | $2.63 | $0.42 | $5.25 | — | — | 100 % | 2M | 1.8M |

1 more provider through partner hosts · from $1.31 in · $2.62 out

A request picks by price (`:floor`) or by speed (`provider.sort`, `:nitro`), or sets a floor on tokens per second. [How routing works](https://docs.opencheap.si/speed)

### Supported parameters

The parameters each provider supports on this model, from its published list and our own tests of whether answers show the parameter taking effect. A test is a snapshot, not a guarantee; `provider.require_parameters` sends a request only to providers that support every parameter it sets. [Required parameters](https://docs.opencheap.si/speed#require-parameters)

- **NanoGPT:** `temperature`, `top_p`, `seed`, `logit_bias`, `presence_penalty`, `stop`, `response_format`, `structured_outputs`, `tools`, `tool_choice`, `reasoning`, `include_reasoning`
- **xAI:** `temperature`, `top_p`, `seed`, `response_format`, `structured_outputs`, `logprobs`, `top_logprobs`, `tools`, `tool_choice`, `reasoning`, `include_reasoning` (stop not confirmed)

## Price history

Each provider's price over the last 24 hours, 7 days and 30 days is charted on [the page](https://opencheap.si/models/grok-4.20#price-history).

## API

Point the OpenAI SDK at OpenCheap and pass the model id `opencheap/grok-4.20`; the rest of your code stays the same.

```bash
curl https://api.opencheap.si/v1/chat/completions \
  -H "Authorization: Bearer $OPENCHEAP_API_KEY" -H "Content-Type: application/json" \
  -d '{ "model": "opencheap/grok-4.20", "messages": [{ "role": "user", "content": "Hi" }] }'
```

```python
import os
from openai import OpenAI
client = OpenAI(base_url="https://api.opencheap.si/v1", api_key=os.environ["OPENCHEAP_API_KEY"])
r = client.chat.completions.create(model="opencheap/grok-4.20",
    messages=[{"role": "user", "content": "Hi"}])
print(r.choices[0].message.content)
```

```javascript
import OpenAI from "openai";
const client = new OpenAI({ baseURL: "https://api.opencheap.si/v1", apiKey: process.env.OPENCHEAP_API_KEY });
const r = await client.chat.completions.create({ model: "opencheap/grok-4.20",
  messages: [{ role: "user", content: "Hi" }] });
console.log(r.choices[0].message.content);
```

## About grok-4.20

grok-4.20 costs from $1.25 per 1M input tokens and $2.50 per 1M output tokens on OpenCheap, with cached input at $0.20 per 1M tokens. Its list price is $1.25 per 1M input tokens and $2.50 per 1M output tokens, the same as here. At that price, a request with 10,000 input tokens and 1,000 output tokens costs about $0.015, and 1,000 such requests about $15.00. Prices as of 2026-12-04 12:01 UTC.

3 providers serve grok-4.20 on OpenCheap. Each request goes to the cheapest healthy provider of the model, and every answer reports what it cost in `usage.cost`. Its context window is 2M tokens (2,000,000), room for roughly 1,500,000 words of English in one request.

grok-4.20 is one of [40 xAI models](https://opencheap.si/models/lab/xai) on OpenCheap. Every model on OpenCheap is called with one key at the same OpenAI-compatible endpoint, `https://api.opencheap.si/v1`.

## Pricing questions

### How much does the grok-4.20 API cost per 1M tokens?

grok-4.20 costs from $1.25 per 1M input tokens and $2.50 per 1M output tokens on OpenCheap, with cached input at $0.20 per 1M tokens. Prices as of 2026-12-04 12:01 UTC.

### What does one grok-4.20 request cost?

A request with 10,000 input tokens and 1,000 output tokens costs about $0.015, and 1,000 such requests about $15.00. Every answer reports its own cost in usage.cost.

### Is grok-4.20 cheaper on OpenCheap than its list price?

Its list price is $1.25 per 1M input tokens and $2.50 per 1M output tokens, the same as here.

### Which providers serve grok-4.20?

3 providers serve grok-4.20 on OpenCheap. Each request goes to the cheapest healthy provider of the model; the table on this page lists every provider with its price, speed and uptime.

### What is the context window of grok-4.20?

Its context window is 2M tokens (2,000,000), room for roughly 1,500,000 words of English in one request.

### How do I call the grok-4.20 API?

Point the OpenAI SDK at https://api.opencheap.si/v1 and pass the model id opencheap/grok-4.20. One OpenCheap key works for every model; the rest of your code stays the same.

## More from xAI

- [Grok 4.7](https://opencheap.si/models/grok-4.7) (`grok-4.7`): $1.26 / $5.03 per 1M · 500K context
- [Grok 2 Vision 1212](https://opencheap.si/models/grok-2-vision-1212) (`grok-2-vision-1212`): $1.80 / $9.00 per 1M
- [grok-3](https://opencheap.si/models/grok-3) (`grok-3`): $3.15 / $15.74 per 1M · 131K context
- [grok-3-beta](https://opencheap.si/models/grok-3-beta) (`grok-3-beta`): $3.16 / $15.79 per 1M · 131K context
- [grok-3-fast-beta](https://opencheap.si/models/grok-3-fast-beta) (`grok-3-fast-beta`): $5.24 / $26.21 per 1M · 131K context
- [grok-3-fast-latest](https://opencheap.si/models/grok-3-fast-latest) (`grok-3-fast-latest`): $5.24 / $26.21 per 1M · 131K context
- [grok-3-latest](https://opencheap.si/models/grok-3-latest) (`grok-3-latest`): $3.15 / $15.75 per 1M · 131K context
- [grok-3-mini-fast-beta](https://opencheap.si/models/grok-3-mini-fast-beta) (`grok-3-mini-fast-beta`): $0.63 / $4.20 per 1M · 131K context

[All 40 xAI models](https://opencheap.si/models/lab/xai)

## Similar models

- [Ergo 1.0](https://opencheap.si/models/ergo-1.0): Other labs · 1M context · $0.94 / $2.83 per 1M · [Compare with grok-4.20](https://opencheap.si/compare/grok-4.20-vs-ergo-1.0)
- [Step 5](https://opencheap.si/models/step-5): StepFun · 1M context · $0.94 / $2.54 per 1M · [Compare with grok-4.20](https://opencheap.si/compare/grok-4.20-vs-step-5)
- [GPT 5.6 Sol](https://opencheap.si/models/gpt-5.6-sol): OpenAI · 1M context · $0.50 / $3.00 per 1M · [Compare with grok-4.20](https://opencheap.si/compare/grok-4.20-vs-gpt-5.6-sol)
- [GLM 5.4](https://opencheap.si/models/glm-5.4): Zhipu · 1M context · $0.70 / $2.20 per 1M, 17 % cheaper · [Compare with grok-4.20](https://opencheap.si/compare/grok-4.20-vs-glm-5.4)
- [Kimi K3](https://opencheap.si/models/kimi-k3): Moonshot · 1M context · $1.57 / $0.94 per 1M, 50 % cheaper · [Compare with grok-4.20](https://opencheap.si/compare/grok-4.20-vs-kimi-k3)
- [Amazon-FMR/Ergo](https://opencheap.si/models/ergo): Other labs · 1M context · $0.90 / $2.70 per 1M · [Compare with grok-4.20](https://opencheap.si/compare/grok-4.20-vs-ergo)

[Compare grok-4.20 with any model](https://opencheap.si/compare)

---

Source: https://opencheap.si/models/grok-4.20 · All models: https://opencheap.si/models · Prices as JSON: https://api.opencheap.si/v1/prices · Index for agents: https://opencheap.si/llms.txt
