Codestral
Mistral AI's code generation model with an undisclosed parameter count, trained on more than 80 programming languages. The current 2508 release shipped July 2025.
- Context
- 128K tokens
- Max output
- 33K
Hosted API price
List price via Mistral · per 1M tokens
- Input
- $0.30 /1M
- Output
- $0.90 /1M
- Hosted by
-
2 providers
Hosted API pricing
How we price
Order
Providers are listed cheapest input rate first, then by output rate, a tie going to the creator's own listing. A provider that lists the model without a published rate sits at the end.
Prices
Base-tier, on-demand rates in USD per 1M tokens, converted at ECB reference rates where a provider publishes in another currency. Cached-input and batch rates show only where a provider publishes them. "Cheapest" marks the one provider with the lowest input and output pair; a tie wears no badge.
Cost
Input rate times the input tokens plus output rate times the output tokens, at the monthly volume set above the table. Cached-input, batch, long-context and reasoning-token billing are not modelled.
Transparency and funding
- Affiliates: Affiliate links are marked. We may earn a commission if you click them, but commissions never affect the order.
Every provider serving Codestral, cheapest input first. Set your monthly volume to see what each would bill.
| Provider | Input /1M | Output /1M | Cost at 10M in + 2M out | Link |
|---|---|---|---|---|
|
|
$0.30 | $0.90 | $4.80 | Visit website |
|
|
$0.30 | $0.90 | $4.80 | Visit website |
Heads up: Base-tier, on-demand rates per 1M tokens; cached, batch and long-context tiers excluded. A provider may serve a shorter context or a quantized build than the creator's release. Verify before provisioning. More on how we price.
Similarly priced models
The models nearest Codestral by blended rate, each at its own cheapest provider.
| Model | Blended /1M | Input /1M | Output /1M | Context | Cutoff | vs Codestral |
|---|---|---|---|---|---|---|
|
|
$0.3667 | $0.20 | $1.20 | 1M | Feb 2026 | −8% |
|
|
$0.375 | $0.20 | $1.25 | 400K | Aug 2025 | −6% |
|
|
$0.3833 | $0.38 | $0.40 | 33K | −4% | |
|
|
$0.3917 | $0.27 | $1.00 | 131K | −2% | |
|
|
$0.3917 | $0.27 | $1.00 | 131K | −2% | |
|
|
$0.40 | $0.30 | $0.90 | 128K | ||
|
|
$0.4117 | $0.27 | $1.12 | 128K | +3% | |
|
|
$0.4135 | $0.276 | $1.101 | 1M | +3% | |
|
|
$0.4333 | $0.20 | $1.60 | 262K | +8% | |
|
|
$0.45 | $0.30 | $1.20 | 1M | +13% | |
|
|
$0.45 | $0.30 | $1.20 | 205K | +13% |
USD per 1M tokens at each model's cheapest listed provider. Blended is the cost of 10M input plus 2M output tokens, spread over the 12M.
Capabilities
What Codestral accepts and can do, as published by Mistral.
- Text Accepts and generates natural-language text.
- Function calling Connect to external tools, APIs, and systems.
- Structured output Return responses in structured formats like JSON.
- File upload Process uploaded documents, spreadsheets, and other files.
Common questions
What is Codestral good for?
High-frequency code completion, fill-in-the-middle and code generation across more than 80 programming languages. It sits in the middle of Mistral's price range.
When is Codestral not a good fit?
Image input: it is text only. Closed weights, so no self-hosting, and its maximum output caps very long single responses.
What is the cheapest way to run Codestral?
The cheapest hosted rate is $0.30 / $0.90 per 1M tokens via Mistral.
Can I self-host Codestral?
No. Mistral does not publish the weights; Codestral is available only through hosted APIs.
More from Mistral
-
Mistral Large 3
Open weights
256K context
From $0.50 / $1.50 /1M in / out at the cheapest provider -
Mistral Small 4
Open weights
256K context
From $0.15 / $0.60 /1M in / out at the cheapest provider -
Ministral 3 14B
Open weights
256K context
From $0.20 / $0.20 /1M in / out at the cheapest provider -
Ministral 3 8B
Open weights
256K context
From $0.15 / $0.15 /1M in / out at the cheapest provider -
Ministral 3 3B
Open weights
256K context
From $0.10 / $0.10 /1M in / out at the cheapest provider -
Mistral Medium 3.5
Open weights
256K context
From $1.50 / $7.50 /1M in / out at the cheapest provider -
Mistral NeMo
Open weights
128K context
From $0.04 / $0.17 /1M in / out at the cheapest provider -
Devstral Medium
128K context