Best LLM API Models for Coding

This guide highlights models whose public metadata indicates coding, programming, developer, or software-oriented use cases.

50Models listed
1M input + 500K outputCost example tokens
USD / 1MNormalized prices

Quick shortlist

Start with MiniMax M3.

This guide starts with coding-oriented models and practical popularity signals so developers can shortlist options faster.

Lead model New🔥MiniMax M3
ProviderMiniMax
Sample cost$0.9
Context1.05M

The ranking is a discovery aid, not a final recommendation. Always compare the model against your workload and verify provider pricing before production use.

How to read this ranking

Models are included when their public model metadata indicates coding, programming, developer, software, or code generation use cases.

Model Ranking

Browse all models
ModelProviderPromptOutputSample costYour CostContextPopularityRelease
New🔥MiniMax M3MiniMax$0.3$1.2$0.9$0.91.05M#4
🔥DeepSeek V4 ProDeepSeek$0.435$0.87$0.87$0.871.05M#5
🔥Claude Sonnet 4.6Anthropic$3$15$10.5$10.51M#6
🔥Owl AlphaOpenRouter$0$0$0$01.05M#7
🔥Claude Opus 4.7Anthropic$5$25$17.5$17.51M#8
🔥Gemini 3 Flash PreviewGoogle$0.5$3$2$21.05M#10
New🔥Step 3.7 FlashStepFun$0.2$1.15$0.77$0.77256K#11
🔥Gemini 2.5 FlashGoogle$0.3$2.5$1.55$1.551.05M#13
🔥Laguna M.1 (free)Poolside$0$0$0$0262.14K#14
🔥Gemini 3.5 FlashGoogle$1.5$9$6$61.05M#16
🔥MiMo-V2.5-ProXiaomi$0.435$0.87$0.87$0.871.05M#17
🔥Claude Opus 4.6Anthropic$5$25$17.5$17.51M#18
Kimi K2.6MoonshotAI$0.66$3.41$2.37$2.37262.14K#21
GLM 5.1Z.ai$0.98$3.08$2.52$2.52202.75K#24
GPT-5.4 MiniOpenAI$0.75$4.5$3$3400K#29
GPT-5.4OpenAI$2.5$15$10$101.05M#30
Gemini 3.1 Pro PreviewGoogle$2$12$8$81.05M#31
Qwen3.7 MaxQwen$1.25$3.75$3.12$3.121M#35
GLM 5Z.ai$0.6$1.92$1.56$1.56202.75K#37
Kimi K2.5MoonshotAI$0.375$2.025$1.39$1.39262.14K#38
MiniMax M2.5MiniMax$0.12$0.48$0.36$0.36204.8K#40
GPT-5 NanoOpenAI$0.05$0.4$0.25$0.25400K#41
Laguna XS.2 (free)Poolside$0$0$0$0262.14K#47
GPT-5.3-CodexOpenAI$1.75$14$8.75$8.75400K#48
Gemini 2.5 ProGoogle$1.25$10$6.25$6.251.05M#57
Qwen3 Coder 480B A35BQwen$0.22$1.8$1.12$1.121.05M#59
GLM 4.7Z.ai$0.4$1.75$1.27$1.27202.75K#63
GPT-5OpenAI$1.25$10$6.25$6.25400K#65
GPT-4.1OpenAI$2$8$6$61.05M#66
Claude Sonnet 4Anthropic$3$15$10.5$10.51M#71
Qwen3.5-9BQwen$0.1$0.15$0.17$0.17262.14K#74
Nemotron 3 Nano 30B A3B (free)NVIDIA$0$0$0$0256K#75
GLM 4.7 FlashZ.ai$0.06$0.4$0.26$0.26202.75K#80
Kimi K2.6 (free)MoonshotAI$0$0$0$0262.14K#83
Qwen3 Coder NextQwen$0.11$0.8$0.51$0.51262.14K#87
Nemotron 3 Nano 30B A3BNVIDIA$0.05$0.2$0.15$0.15262.14K#89
Qwen3 Next 80B A3B InstructQwen$0.09$1.1$0.64$0.64262.14K#95
Qwen2.5 7B InstructQwen$0.04$0.1$0.09$0.09131.07K#106
GPT-5.2-CodexOpenAI$1.75$14$8.75$8.75400K#108
GPT-5 CodexOpenAI$1.25$10$6.25$6.25400K#111
GPT-5.1-CodexOpenAI$1.25$10$6.25$6.25400K#113
Claude 3.5 HaikuAnthropic$0.8$4$2.8$2.8200K#118
o3 MiniOpenAI$1.1$4.4$3.3$3.3200K#122
Ring-2.6-1TinclusionAI$0.075$0.625$0.39$0.39262.14K#123
Qwen3 Coder 30B A3B InstructQwen$0.07$0.27$0.21$0.21160K#126
Mistral Medium 3.5Mistral$1.5$7.5$5.25$5.25262.14K#131
Grok Build 0.1xAI$1$2$2$2256K#137
GPT-5.1-Codex-MiniOpenAI$0.25$2$1.25$1.25400K#141
Qwen2.5 72B InstructQwen$0.36$0.4$0.56$0.56131.07K#142
Devstral 2 2512Mistral$0.4$2$1.4$1.4262.14K#144

Pricing FAQ

How is the sample workload cost calculated?

The sample workload uses 1,000,000 input tokens plus 500,000 output tokens, then applies each model's normalized USD price per 1 million tokens.

Why do input and output token prices matter separately?

Many applications are output-token heavy, while retrieval and classification workloads may be input-token heavy. Comparing both prices helps avoid picking a model that is cheap for the wrong workload shape.

Should I verify prices before production use?

Yes. AI Model Matrix normalizes public pricing metadata for comparison, but provider availability, limits, and prices can change. Always verify the final contract or provider dashboard before production use.

Related Guides

Cheapest LLM APIs

Sort models by estimated workload cost and normalized token prices.

Open guide

Largest Context Windows

Find models for long documents, retrieval, and codebase context.

Open guide

Coding Models

Compare code-oriented models by cost, context, and practical popularity signals.

Open guide

Free Models

Browse zero-price models for prototypes and evaluation.

Open guide

RAG Models

Start from large context windows and practical input-cost constraints.

Open guide

Chatbot Costs

Find budget-sensitive models for output-heavy assistant traffic.

Open guide

Cost Calculator

Enter your own input and output token volume before narrowing the shortlist.

Estimate cost