Cheapest models for coding
Ranked by input $/Mtoken, then output. Strong code generation and agent coding loops.
- 1Hy3 preview
Tencent · 262,144 context
Input
$0.063/M
Output
$0.210/M
- 2DeepSeek V4 Flash
DeepSeek · 1,048,576 context
Input
$0.098/M
Output
$0.196/M
- 3Mistral Small 3.2 24B
Mistral · 131,072 context
Input
$0.100/M
Output
$0.300/M
- 4Llama 4 Scout
Meta · 10,000,000 context
Input
$0.100/M
Output
$0.300/M
- 5MiMo-V2.5
Xiaomi · 1,048,576 context
Input
$0.140/M
Output
$0.280/M
- 6GPT-4o-mini
OpenAI · 128,000 context
Input
$0.150/M
Output
$0.600/M
- 7Llama 4 Maverick
Meta · 1,048,576 context
Input
$0.200/M
Output
$0.800/M
- 8GPT-5.4 Nano
OpenAI · 400,000 context
Input
$0.200/M
Output
$1.25/M
- 9DeepSeek V3
DeepSeek · 131,072 context
Input
$0.200/M
Output
$0.800/M
- 10Nex-N2-Pro
Nex Agi · 262,144 context
Input
$0.250/M
Output
$1.00/M
- 11DeepSeek V3.2
DeepSeek · 163,840 context
Input
$0.269/M
Output
$0.400/M
- 12Qwen3 Coder 480B A35B
Qwen · 1,048,576 context
Input
$0.300/M
Output
$1.00/M
- 13MiniMax M3
Minimax · 1,048,576 context
Input
$0.300/M
Output
$1.20/M
- 14KAT-Coder-Pro V2
Kwaipilot · 256,000 context
Input
$0.300/M
Output
$1.20/M
- 15Qwen3.7 Plus
Qwen · 1,000,000 context
Input
$0.320/M
Output
$1.28/M
- 16DeepSeek V4 Pro
DeepSeek · 1,048,576 context
Input
$0.435/M
Output
$0.870/M
- 17MiMo-V2.5-Pro
Xiaomi · 1,048,576 context
Input
$0.435/M
Output
$0.870/M
- 18Kimi K2.6
Moonshotai · 262,144 context
Input
$0.684/M
Output
$3.42/M
- 19R1
DeepSeek · 163,840 context
Input
$0.700/M
Output
$2.50/M
- 20GPT-5.4 Mini
OpenAI · 400,000 context
Input
$0.750/M
Output
$4.50/M
- 21Qwen3 Max
Qwen · 262,144 context
Input
$0.780/M
Output
$3.90/M
- 22Kimi K2.7 Code
Moonshotai · 262,144 context
Input
$0.850/M
Output
$3.80/M
- 23GLM 5.2
Z Ai · 1,048,576 context
Input
$0.952/M
Output
$2.99/M
- 24GLM 5.1
Z Ai · 202,752 context
Input
$0.966/M
Output
$3.04/M
- 25Claude Haiku 4.5
Anthropic · 200,000 context
Input
$1.00/M
Output
$5.00/M
- 26GPT-5.6 Luna
OpenAI · 1,050,000 context
Input
$1.00/M
Output
$6.00/M
- 27Muse Spark 1.1
Meta · 1,048,576 context
Input
$1.25/M
Output
$4.25/M
- 28Gemini 2.5 Pro
Google · 1,048,576 context
Input
$1.25/M
Output
$10.00/M
- 29Qwen3.7 Max
Qwen · 1,000,000 context
Input
$1.48/M
Output
$4.42/M
- 30Gemini 3.5 Flash
Google · 1,048,576 context
Input
$1.50/M
Output
$9.00/M
- 31Grok 4.5
xAI · 500,000 context
Input
$2.00/M
Output
$6.00/M
- 32Mistral Large
Mistral · 128,000 context
Input
$2.00/M
Output
$6.00/M
- 33o3
OpenAI · 200,000 context
Input
$2.00/M
Output
$8.00/M
- 34Claude Sonnet 5
Anthropic · 1,000,000 context
Input
$2.00/M
Output
$10.00/M
- 35Gemini 3.1 Pro Preview
Google · 1,048,576 context
Input
$2.00/M
Output
$12.00/M
- 36GPT-4o
OpenAI · 128,000 context
Input
$2.50/M
Output
$10.00/M
- 37GPT-5.6 Terra
OpenAI · 1,050,000 context
Input
$2.50/M
Output
$15.00/M
- 38GPT-5.4
OpenAI · 1,050,000 context
Input
$2.50/M
Output
$15.00/M
- 39Claude Sonnet 4.5
Anthropic · 1,000,000 context
Input
$3.00/M
Output
$15.00/M
- 40Claude Sonnet 4
Anthropic · 1,000,000 context
Input
$3.00/M
Output
$15.00/M