Best LLM for RAG
Ranked by the cost of one RAG request: 10,000 retrieved tokens (assumed 80% cached) plus 500 output tokens. Cached input is used where the provider publishes a cache rate, otherwise the standard input rate. Re-run with your own retrieval size in the calculator.
Top 15 for RAG (per request cost)
| # | Model | Provider | Cost / request | Cached input $/M | Output $/M | Context |
|---|---|---|---|---|---|---|
| 1 | GPT-6 Luna | OpenAI | $0.0003 | $0.01 | $0.50 | 1,050,000 |
| 2 | Claude Haiku 5.5 | Anthropic | $0.0003 | $0.01 | $0.50 | 200,000 |
| 3 | Mistral Small 4 | Mistral AI | $0.0004 | $0.015 | $0.60 | 256,000 |
| 4 | DeepSeek V4.1 Flash | DeepSeek | $0.0007 | $0.006 | $1.20 | 1,100,000 |
| 5 | GPT-5.6 Luna | OpenAI | $0.0008 | $0.02 | $1.20 | 1,050,000 |
| 6 | GPT-5.4 nano | OpenAI | $0.0008 | $0.02 | $1.25 | 400,000 |
| 7 | Gemini 3.1 Flash-Lite | $0.0010 | $0.025 | $1.50 | 1,000,000 | |
| 8 | Gemini 3.5 Flash-Lite | $0.0015 | $0.03 | $2.50 | 1,000,000 | |
| 9 | Mistral Large 4 | Mistral AI | $0.0018 | $0.07 | $2.10 | 1,000,000 |
| 10 | DeepSeek V4 Pro | DeepSeek | $0.0024 | $0.044 | $3.96 | 1,000,000 |
| 11 | Gemini 3.8 Flash | $0.0026 | $0.075 | $3.75 | 1,000,000 | |
| 12 | Gemini 3.6 Flash | $0.0026 | $0.075 | $3.75 | 1,000,000 | |
| 13 | GPT-6.1 Terra | OpenAI | $0.0030 | $0.05 | $5 | 1,050,000 |
| 14 | GPT-5.4 mini | OpenAI | $0.0030 | $0.075 | $4.50 | 400,000 |
| 15 | Grok 4.3 | xAI | $0.0033 | $0.20 | $2.50 | 1,000,000 |
Frequently asked
What makes an LLM good for RAG?
A large context window for the retrieved chunks, a low cached-input rate because RAG prefixes are repeated, and a reasonable output price. Cache hits are where RAG workloads save the most.
How much does a RAG request cost?
At 10K retrieved tokens with an 80% cache hit, the cheapest models land around $0.001 per request and frontier reasoning models around $0.02. Multiply by your daily query volume to size the bill.
Should I use a long-context model for RAG?
Only if your retrieved set exceeds the standard window. Otherwise a 1M-context model is wasted money; a 128K model with cheap cached input is usually the better fit.
Browse all 45 models · Compare two models