Grok 4.6 from SpaceXAI is now available on AI Gateway. The model has a 500K token context window and accepts text and image inputs. Grok 4.6 supports low, medium, high, and xhigh reasoning levels and defaults to high.
To use Grok 4.6, set model
to xai/grok-4.6
in the [AI SDK](https://ai-sdk.dev/):
To use it in a [coding agent](https://vercel.com/docs/ai-gateway/coding-agents), run `vercel ai-gateway coding-agents setup`
to connect Claude Code, Codex, OpenCode, or Pi, then select xai/grok-4.6
inside the agent.
To try Grok 4.5 with no code, try the model in the model playground. AI Gateway provides a unified API for calling models, tracking usage and cost, and configuring retries, failover, and performance optimizations for higher-than-provider uptime. It includes built-in custom reporting, Zero Data Retention support, budgets for API keys, routing rules, and more.
AI Gateway reflects provider pricing with no markup and does not charge a platform fee on inference, including on Bring Your Own Key (BYOK) requests.