Grok 4.20
x-ai/grok-4.20Grok 4.20 is a reasoning model from xAI with industry-leading speed and agentic tool calling capabilities. It combines the lowest hallucination rate on the market with strict prompt adherance, delivering consistently precise and truthful responses.
- Input price
- $1.25USD / 1M tokens
- Output price
- $2.50USD / 1M tokens
- Context window
- N/A
- Max output
- 2M
Try the model
Playground
Try a prompt
Your response will appear here
Choose an example or write a prompt, then click Run.
Model card
Specifications
Pricing
- Input
- $1.25 / 1M tokens
- Output
- $2.50 / 1M tokens
- Cache read
- $0.20 / 1M tokens
Context & modalities
- Max output
- 2,000,000 tokens
- Input
- Text, image
- Output
- Text
Capabilities
- Chat
- Supported
- Vision
- Supported
- Reasoning
- Supported
- Structured output
- Supported
- Function calling
- Supported
- Audio input
- Not supported
Access
- Provider
- xAI
- Model ID
- x-ai/grok-4.20
- Execution
- sync
- Base URL
- https://api.sandbase.ai
- API
- Chat Completions API
- Endpoint
- /v1/chat/completions
Start building
Send your first request
OpenAI-compatible endpoint with unified authentication and usage tracking.
# The quoted heredoc keeps Unicode and shell metacharacters unchanged.
result=$(curl --fail-with-body --silent \
-X POST "https://api.sandbase.ai/v1/chat/completions" \
-H "Authorization: Bearer $SANDBASE_API_KEY" \
-H "Content-Type: application/json" \
--data-binary @- <<'SANDBASE_JSON'
{
"model": "x-ai/grok-4.20",
"messages": [
{
"role": "user",
"content": "Hello"
}
],
"max_tokens": 2048
}
SANDBASE_JSON
)
printf '%s\n' "$result"Choose your model
Compare models
Questions
FAQ
How do I call xAI Grok 4.20 through SandBase?
Create a SandBase API key, then send requests with the model ID "x-ai/grok-4.20" to Chat Completions API (/v1/chat/completions) at https://api.sandbase.ai. The request examples on this page show the exact payload.
How much does xAI Grok 4.20 cost?
$1.25 per 1M input tokens and $2.50 per 1M output tokens, billed per request from your SandBase balance. Discounts, when available, are shown in the pricing on this page.
Which features does xAI Grok 4.20 support?
xAI Grok 4.20 supports vision (image input), reasoning, function calling, structured output. See Specifications above for the full list.
Do I need a separate xAI account?
No. One SandBase API key and balance gives you access to xAI Grok 4.20 and the other models in the catalog; you do not need to sign up with xAI separately.
