Anthropic: Claude Sonnet 5 vs google/gemini-3.1-pro

They cost about the same for input tokens: Anthropic: Claude Sonnet 5 $2.00 per M, google/gemini-3.1-pro $2.00 per M. Anthropic: Claude Sonnet 5 is 1.2× cheaper for output tokens: Anthropic: Claude Sonnet 5 costs $10.00 per M and google/gemini-3.1-pro costs $12.00 per M. Both read up to 1,000,000 tokens of context. Anthropic: Claude Sonnet 5 accepts file, image, text; google/gemini-3.1-pro accepts image, text.

Anthropic: Claude Sonnet 5google/gemini-3.1-pro
Model idanthropic/claude-sonnet-5google/gemini-3.1-pro
Input$2.00 per M$2.00 per M
Output$10.00 per M$12.00 per M
Context length1,000,000 tokens1,000,000 tokens
Acceptsfile, image, textimage, text
Producestexttext
Served byanthropicdeepinfra

Prices are the providers' list prices per million tokens, as of . Both run on your own provider key through one OpenAI-compatible endpoint, with no fee on the tokens.