AI models with the longest context windows

Ranked by maximum context, with the price to fill it. A million-token window costs whatever a million input tokens cost, so the useful comparison is window size and input rate together — which is what this table shows.

List prices checked

All 25, ranked

#NameProviderInputNotes
1Gemini 2.5 ProGoogle$1.25/1M tokens1M context · $1.25 in / $10.00 out
2Gemini 2.5 FlashGoogle$0.300/1M tokens1M context · $0.300 in / $2.50 out
3Gemini 2.5 Flash-LiteGoogle$0.100/1M tokens1M context · $0.100 in / $0.400 out
4GPT-4.1OpenAI$2.00/1M tokens1M context · $2.00 in / $8.00 out
5GPT-4.1 miniOpenAI$0.400/1M tokens1M context · $0.400 in / $1.60 out
6DeepSeek-V4-FlashDeepSeek$0.140/1M tokens1M context · $0.140 in / $0.280 out
7DeepSeek-V4-ProDeepSeek$0.435/1M tokens1M context · $0.435 in / $0.870 out
8GPT-5OpenAI$1.25/1M tokens400K context · $1.25 in / $10.00 out
9GPT-5 miniOpenAI$0.250/1M tokens400K context · $0.250 in / $2.00 out
10GPT-5 nanoOpenAI$0.050/1M tokens400K context · $0.050 in / $0.400 out
11CodestralMistral AI$0.300/1M tokens262K context · $0.300 in / $0.900 out
12Grok 4xAI$3.00/1M tokens256K context · $3.00 in / $15.00 out
13Cohere Command ACohere$2.50/1M tokens256K context · $2.50 in / $10.00 out
14Claude Fable 5Anthropic$10.00/1M tokens200K context · $10.00 in / $50.00 out
15Claude Opus 5Anthropic$5.00/1M tokens200K context · $5.00 in / $25.00 out
16Claude Sonnet 5Anthropic$3.00/1M tokens200K context · $3.00 in / $15.00 out
17Claude Haiku 4.5Anthropic$1.00/1M tokens200K context · $1.00 in / $5.00 out
18OpenAI o3OpenAI$2.00/1M tokens200K context · $2.00 in / $8.00 out
19OpenAI o4-miniOpenAI$1.10/1M tokens200K context · $1.10 in / $4.40 out
20Grok 3 minixAI$0.300/1M tokens131K context · $0.300 in / $0.500 out
21Mistral LargeMistral AI$2.00/1M tokens131K context · $2.00 in / $6.00 out
22Mistral SmallMistral AI$0.100/1M tokens131K context · $0.100 in / $0.300 out
23GPT-4oOpenAI$2.50/1M tokens128K context · $2.50 in / $10.00 out
24GPT-4o miniOpenAI$0.150/1M tokens128K context · $0.150 in / $0.600 out
25Cohere Command RCohere$0.150/1M tokens128K context · $0.150 in / $0.600 out

Source: Google (May 2026) · OpenAI (May 2026) · DeepSeek (August 2026) · Mistral AI (May 2026) · xAI (May 2026) · Cohere (May 2026). Published list prices only — committed-use discounts, regional variation, and per-request charges are not included. Not yet independently re-checked against the vendor’s page.

Questions

What is the ai models with the longest context windows in 2026?
Gemini 2.5 Pro from Google tops this ranking at $1.25/1M tokens. The full table below shows all 25 entries with the same measure applied to each.
How is this ranking calculated?
Ranked by maximum context, with the price to fill it. A million-token window costs whatever a million input tokens cost, so the useful comparison is window size and input rate together — which is what this table shows. Every figure is the provider's own published list price, linked in the source column and stamped with the month it was checked.
Why is the cheapest option not always the right one?
Because a single axis never captures the whole bill. A provider with the lowest storage rate may have the highest egress rate; a model with the cheapest input tokens may be the most expensive for agentic work. The comparison pages model both sides against identical workloads, which is the check worth doing before switching.

Other rankings