Comprehensive side-by-side LLM comparison
Gemini 3.1 Pro offers 850.1K more tokens in context window than Claude 3.7 Sonnet. Gemini 3.1 Pro is $4.00 cheaper per million tokens. Claude 3.7 Sonnet is available on 3 providers. Both models have their strengths depending on your specific coding needs.
Anthropic
Claude Sonnet 3.7, released by Anthropic in February 2025, is a large language model from the Claude 3 family featuring hybrid reasoning with configurable extended thinking. It supports a 200K token context window, 64K maximum output tokens (128K in beta), and native image understanding. Sonnet 3.7 targets complex coding, mathematics, and scientific reasoning tasks where extended chain-of-thought processing provides meaningful improvements in output quality.
Google DeepMind
Gemini 3.1 Pro is a multimodal language model from Google DeepMind, released in preview in February 2026 as a point-version upgrade to Gemini 3 Pro focused on improving reasoning depth, factual grounding, and coding and agentic task performance. The model accepts text, images, video, audio, and PDFs as inputs across a 1M token context window, extending the multimodal breadth of the Gemini 3 series with a companion endpoint specifically optimized for custom tool use in agentic pipelines. Google describes it as built to refine the reliability and performance of the Gemini 3 Pro series, reflecting an incremental engineering iteration rather than an architectural overhaul.
12 months newer

Claude 3.7 Sonnet
Anthropic
2025-02-24

Gemini 3.1 Pro
Google DeepMind
2026-02-19
Cost per million tokens (USD)
Claude 3.7 Sonnet
Gemini 3.1 Pro
Context window and performance specifications
Claude 3.7 Sonnet
2024-10
Gemini 3.1 Pro
2025-01
Available providers and their performance metrics
Claude 3.7 Sonnet
Anthropic
AWS Bedrock
Google Cloud Vertex AI
Gemini 3.1 Pro
Claude 3.7 Sonnet
Gemini 3.1 Pro
Claude 3.7 Sonnet
Gemini 3.1 Pro