How to choose an AI coding model
Coding models differ far more on real repositories than on toy puzzles. This guide shows what to measure, what it costs per month, and which models lead today, using live data from our catalogue.

Coding models by the numbers
Quick answer: top picks today
The three highest-rated models you can call on LLM API right now.
Find your model in 3 questions
1. What matters most?
2. Where will it run?
3. Budget?
Your top 3 update as you answer, from live catalogue data.
Price vs rating
Each dot is a model you can use. Up is better rated, left is cheaper. Hover for details, click to open.
Largest context windows
What will it cost per month?
Drag the slider to your expected volume. Prices are live list prices of the top models.
| Model | Per month |
|---|
Key numbers to know
| 1 line of code | ≈ 10 tokens |
| A 300-line file | ≈ 3,000 tokens |
| A mid-size repo map sent as context | 30–100K tokens |
| One agent step (read, edit, test) | 5–20K tokens |
| Output vs input price | Output usually costs 3–5× more per token |
How to choose, step by step
Decide between autocomplete and agents
Inline completion needs a fast, cheap model with low latency. Agents that edit several files and run tests need the strongest model you can afford, because one failed step costs more than the token difference.
Check real-repo benchmarks, not puzzles
SWE-bench Verified asks a model to fix real GitHub issues and passes only if the project's own tests pass. It predicts agent quality far better than short function-writing tests.
Size the context to your codebase
A 128K window fits a focused module plus instructions. For whole-repo reasoning look for 200K–1M tokens, and remember you pay for every token you resend.
Confirm tool calling and structured output
Coding agents depend on reliable function calls and JSON. Check the Tools and JSON chips in the category table before you commit.
Keep a cheaper fallback
Route easy tasks (renames, docstrings, tests) to a cheaper model and send hard ones to the top model. Most teams cut cost by half this way.
Decision diagram
Answer top to bottom. The first yes is your starting point.
What the research says
The independent benchmarks that matter for this category, with links to the papers and methodology behind each one.
SWE-bench Verified ↗
Share of real GitHub issues a model fixes so that the project's tests pass
Paper: SWE-bench: Can Language Models Resolve Real-World GitHub Issues? (Jimenez et al., ICLR 2024) ↗LMArena coding leaderboard ↗
Blind human votes between two models' answers to coding prompts (Elo)
Paper: Chatbot Arena: An Open Platform for Evaluating LLMs by Human Preference (Chiang et al., 2024) ↗Artificial Analysis Coding Index ↗
Independent combined score across LiveCodeBench, SciCode and Terminal-Bench
Methodology: Artificial Analysis Intelligence Benchmarking ↗Aider polyglot ↗
Edits across 6 programming languages applied to real exercises
Write-up: Aider's polyglot benchmark, how the 225 exercises were chosen ↗Reviews: what the labs and sources say
Verbatim quotes from public sources. Click through to read them in context.
“GPT‑5‑Codex is a version of GPT‑5 further optimized for agentic software engineering in Codex.”GPT-5 Codex · OpenAI, Introducing upgrades to Codex, Sep 15, 2025
“Qwen3-Coder-480B-A35B-Instruct sets new state-of-the-art results among open models on Agentic Coding, Agentic Browser-Use, and Agentic Tool-Use, comparable to Claude Sonnet 4.”Qwen3 Coder Plus · Qwen Team blog, Qwen3-Coder (the model behind Qwen3 Coder Plus), Jul 22, 2025
“Devstral Small 1.1 achieves a score of 53.6% on SWE-Bench Verified, and sets a new state-of-the-art for open models without test-time scaling.”Devstral Small 1.1 · Mistral AI, Upgrading agentic coding capabilities with the new Devstral models, Jul 10, 2025
“How the world’s leading enterprises are using integrated coding solutions from Mistral AI to cut development, review, and testing time by 50%”Codestral · Mistral AI, Announcing Codestral 25.08, Jul 30, 2025
Mistakes to avoid
Picking by HumanEval-style scores. Nearly every model scores above 85%, so these tests no longer separate models.
Ignoring output price. Agents write a lot, and output tokens usually cost 3–5× more than input.
Sending the whole repo every turn. Retrieve only the files that matter; you pay for every resent token.
Comparing SWE-bench numbers from different agent setups. The scaffolding changes the score as much as the model.
FAQ
What is the best model for coding right now?
The one at the top of the Rating column on our coding page for your budget. The rating combines real usage, the LMArena coding leaderboard and Artificial Analysis results, and updates every Sunday.
Are open-weight coding models good enough?
For many tasks, yes. Qwen3-Coder and DeepSeek models are close to closed models on agent benchmarks and can run on your own servers.
How much does a coding agent cost per month?
Use the calculator above. A small team running an agent for a few hours a day typically uses 20–100 million tokens a month.
Should I use one model or several?
Several. Route simple edits to a cheap model and hard, multi-file changes to a top model. With LLM API you switch by changing one model name.