Google Gemini API vs xAI Grok API API Pricing (2026) — Per-Token Cost Comparison

Google Gemini API vs xAI Grok API

LLM API Providers pricing comparison · 2026

Google Gemini API pricing ranges from $0–$18/per million tokens, while xAI Grok API ranges from $0.2–$30/per million tokens. These products use different pricing models (Usage-based (pay per token/image/minute) vs Per-seat subscription), so a direct price comparison isn't meaningful — costs depend on usage volume and mix.

LLM API Providers

Google Gemini API

$0–$18
/per million tokens
4 plans · Free tier
Full pricing breakdown →
VS
LLM API Providers

xAI Grok API

$0.2–$30
/per million tokens
2 plans
Full pricing breakdown →

Different Pricing Models

Direct price comparison isn't meaningful here — Google Gemini API uses Usage-based (pay per token/image/minute) pricing while xAI Grok API uses Per-seat subscription pricing. Your actual cost will depend on usage volume, team size, or both. Here's each product in its native unit.

Usage-based (pay per token/image/minute)

Google Gemini API

From $0.025 per 1M cached input tokens
See full Google Gemini API pricing →
vs
Per-seat subscription

xAI Grok API

$0.2–$30 / per million tokens
See full xAI Grok API pricing →

Google Gemini API and xAI Grok API are two leading LLM API providers. This page compares their per-token pricing, available models, and tier structure so you can pick the right backend for your workload — whether you're optimizing for cost per 1M tokens, latency, or model quality.

Plan-by-Plan Pricing

Plan Google Gemini API xAI Grok API
Free Free /month Custom
Flash-Lite (Paid) Custom Custom
Flash (Paid) Custom
Pro (Paid) Custom