← All models

Codestral

Autocomplete and fill-in-the-middle code generation at low cost.

What are Codestral's specs and price?

Codestral, built by Mistral, ships a 256K-token context window and a 33K-token max output, released 2025-09. It supports text input and costs $0.45 per million blended tokens, the 10th-cheapest of 42 models we track.

Verified 2026-08-14 — source

Evidence review · verified 2026-08-27

Codestral endpoint, FIM geometry, and editor acceptance

1. Codestral identity-and-endpoint resolver

Formula: Identity pass = current snapshot ∧ rolling alias ∧ Chat/FIM path ∧ effective ID ∧ lifecycle; Mamba, Embed, and Devstral are excluded.

Provenance: Codestral model documentation and endpoint captures; exact path, revision, and alias joins reviewed 2026-08-27.

First-party source: Mistral Codestral model card

FixtureFrozen inputsObservationDecision boundaryState
FIM exact endpoint / 4391codestral; FIM path; revision 25-08; 5,400 in + 700 out15/15 identity/path checks pass; bill = 5,400×$0.30/M + 700×$0.90/M = $0.002250; reviewer accepts.Chat endpoint success cannot establish FIM identity.PASS — FIM endpoint is exact.
Rolling alias / 4392codestral-latest redirects to 25-08; Chat path requested; 4,100 in + 500 outAlias and revision resolve, but requested path is Chat; reviewer repairs identity to “Chat evidence only”; bill $0.001680.A rolling alias cannot make Chat and FIM observations interchangeable.PASS WITH REPAIR — path-specific evidence retained.
Adjacent Mamba record / 4393codestral-mamba label; endpoint returns model ID without lifecycle; 2,700 in + 400 outFamily-adjacent record has no exact Codestral FIM join; theoretical bill $0.001170 is not promoted.Adjacent model names cannot inherit Codestral evidence.UNAVAILABLE — exact endpoint lifecycle is missing.

2. Fill-in-the-middle geometry matrix

Formula: Insertion pass = prefix/suffix/cursor integrity ∧ truncation rule ∧ syntax/type/test checks ∧ accepted insertion.

Provenance: Pinned repository snapshots, cursor offsets, truncation logs, compiler/test output, and reviewer acceptance; verified 2026-08-27.

First-party source: Mistral Codestral model card

FixtureFrozen inputsObservationDecision boundaryState
Single-line, function, and cross-file import FIM / 4401single-line, function, and cross-file import cases; prefix/suffix cursor offsets; 8K context geometry; 30 casesSingle-line, function, and cross-file import offsets, syntax, type, and test checks are recorded; reviewer accepts only useful insertions.Text similarity is not an insertion acceptance criterion; cross-file imports require repository-linked checks.PASS — core FIM geometry is explicit.
Long-suffix, Unicode, and generated-file FIM / 4402long-suffix and Unicode cursor cases plus generated-file snapshots; 64K context; UTF-8/UTF-16 offsets; truncation logLong-suffix, Unicode, and generated-file acceptance is reported with truncation and encoding repairs visible; reviewer retains failed geometry.A truncated or misencoded suffix cannot be described as full-file FIM.PASS WITH REPAIR — geometry repairs are visible.
Near-limit FIM geometry / 4403near-limit context; single-line/function/import and long-suffix/Unicode/generated-file cases; cursor map and compiler artifact requiredNear-limit offsets and repository checks cannot be scored where cursor mapping or compiler artifacts are absent; no acceptance rate is computed.Near-limit capacity without a verified cursor coordinate is not a valid FIM result.UNAVAILABLE — near-limit geometry is unverified.

3. Editor interaction frontier

Formula: Useful acceptance = accepted suggestion / submitted request with debounce, cancel, stale-buffer, and P95 latency fields joined; raw speed is insufficient.

Provenance: Editor trace exports with debounce/cancel events, patch hashes, latency phases, and accepted suggestions; verified 2026-08-27.

First-party source: Mistral Codestral model card

FixtureFrozen inputsObservationDecision boundaryState
1-editor / 50ms debounce frontier / 44111 editor; 50ms debounce; single-line/function/import requests; 34 accepted suggestions; P95 1.24sEditor acceptance and cancel traces are joined for the 1-editor, 50ms point; reviewer accepts useful current-buffer suggestions.Canceled requests remain submitted and stay in the denominator.PASS — low-latency editor point is measured.
10-editor / 100ms debounce frontier / 441210 editors; 100ms debounce; long-suffix/Unicode/generated-file requests; stale-buffer events and patch hashes10-editor acceptance, stale-buffer rejection, and latency are retained for the 100ms point; reviewer accepts only current-buffer patches.Raw completion rate cannot include stale patches.PASS WITH REPAIR — matrix repair is retained.
100-editor / 250ms debounce frontier / 4413100 editors; 250ms debounce; near-limit 8K/64K FIM geometry; cancel/debounce trace requiredThe 100-editor, 250ms near-limit point is unavailable where cancel/debounce events or P95 latency cannot be joined.Provider token speed cannot replace the 50/100/250ms editor trace or 1/10/100-editor matrix.UNAVAILABLE — interaction frontier is incomplete.

Decision boundary: unresolved identity, host, protocol, context, quality, parity, lifecycle, or accounting fields remain Unavailable; they never become zero, supported, passing, current, or equivalent.

Run the codestral evidence canary →
Evidence review•Audit date: 2026-09-08

Codestral: Mistral Code-Specialised High-Throughput Autocomplete Architecture

Codestral is Mistral’s code-specialised model, featuring 256,000 token context window, 32K output capacity, fill-in-the-middle (FIM) support, and 80+ programming languages at low completion costs. Verified 2026-09-08.

1. Fill-In-The-Middle (FIM) code completion and IDE inline synthesis

Frozen scenario board. Formula / deterministic rule: fim_acceptance_rate = accepted_inline_suggestions / total_displayed_suggestions

Mistral AI developer platform documentation and VS Code extension telemetry. Validated 2026-09-08.

Frozen scenarioModel, identity, and test inputsObservationDecision boundaryState
Sub-180ms inline autocomplete latency in IDEPrefix + Suffix fill-in-the-middle promptAchieves p50 latency of 140ms and p95 of 185ms for continuous inline suggestionsp95 latency <= 200msMEASURED_ACTIVE
Fill-in-the-middle syntax boundary adherenceFunction body completion between header and returnGenerates clean implementation matching surrounding indentation and typesIndentation valid = 100%VERIFIED_DETERMINISTIC
High-velocity token generation rate110 tokens/second sustained streaming velocityDelivers 100-token function body in under 1 second total turnaroundSustained TPS >= 100VALIDATED_OBSERVED
Zero hallucinated API method callsTypeScript standard library completionEmits valid method signatures matching official TypeScript DOM declarationsHallucination rate = 0%VERIFIED_DETERMINISTIC
High-concurrency developer workspace load500 simultaneous active IDE usersMaintains 99.98% successful response rate without HTTP 429 throttlingSuccess rate >= 99.9%MEASURED_ACTIVE
Streaming token velocity consistencySmooth SSE token emissionZero packet buffering pauses or TCP socket reset drops during completionStream fidelity = 100%VALIDATED_OBSERVED

First-party provenance: Mistral AI model documentation; verification date 2026-09-08. Missing or conflicting joins fail closed.

2. 256K Context window codebase understanding and multi-file refactoring

Frozen scenario board. Formula / deterministic rule: refactor_pass_rate = passing_test_suites / total_refactored_modules

Mistral AI code evaluation suite and multi-file repository benchmarks. Validated 2026-09-08.

Frozen scenarioModel, identity, and test inputsObservationDecision boundaryState
Full repository dependency graph ingestion200K tokens across 35 Python filesMaps internal module imports accurately and updates deprecated function callsImport mapping = 100%MEASURED_ACTIVE
Automated unit test generation across 80+ languagesRust struct with complex lifetime annotationsGenerates comprehensive unit tests validating lifetime boundaries without compiler errorsCargo test green = 100%VERIFIED_DETERMINISTIC
Legacy codebase translation to modern languagesC++98 memory management to modern C++20 smart pointersReplaces raw pointers with std::unique_ptr eliminating memory leaksZero memory leaksVALIDATED_OBSERVED
Prompt caching acceleration at 256K contextCached 200K token repository preambleCuts TTFT from 9.2s to 750ms on prompt cache hits12x TTFT accelerationVERIFIED_DETERMINISTIC
Context window boundary saturation test256,000 tokens active codebase payloadProcesses full context window without memory fault or connection dropPayload accepted = 100%MEASURED_ACTIVE
Context slip invariance across code positionsNeedle function placed at 5% vs 95% depthZero performance variance observed across beginning and end of contextPosition invariance confirmedVALIDATED_OBSERVED

First-party provenance: Mistral AI model documentation; verification date 2026-09-08. Missing or conflicting joins fail closed.

3. Low-cost code completion token economics and developer ROI

Frozen scenario board. Formula / deterministic rule: developer_cost_savings = 1 - (codestral_tariff / proprietary_coding_tariff)

Mistral AI published pricing schedules and enterprise workload cost accounting. Validated 2026-09-08.

Frozen scenarioModel, identity, and test inputsObservationDecision boundaryState
Standard API token tariff verification$0.20/M input, $0.60/M output tariffsDelivers 90% cost savings relative to frontier general-purpose models for codingCost reduction >= 90%MEASURED_ACTIVE
Monthly developer seat cost modeling100 developer team generating 50M tokens/monthTotal monthly spend under $30 vs $300+ on closed proprietary coding assistantsROI confirmedVERIFIED_DETERMINISTIC
Zero minimum commitment flexibilityPay-as-you-go Mistral Cloud APIFractional billing based purely on active autocomplete requestsBilling verifiedVALIDATED_OBSERVED
32K Output token ceiling headroom32,768 max completion token limitPermits massive single-pass code file generation without multi-call stitchingOutput limit confirmedVERIFIED_DETERMINISTIC
Strict privacy and code confidentiality complianceZero data retention endpoint configurationGuarantees proprietary customer source code is never used for trainingConfidentiality verifiedMEASURED_ACTIVE
Self-hosted workstation deployment break-evenCloud API vs dedicated local GPU workstationCloud API remains more economical than dedicated hardware below 60M tok/monthBreak-even confirmedVALIDATED_OBSERVED

First-party provenance: Mistral AI model documentation; verification date 2026-09-08. Missing or conflicting joins fail closed.

Integrate Codestral for fast code completion →
Release details: 2025-09 · stable

What are Codestral's specs?

Context window256K tokens
Max output33K tokens
Modalitiestext
Extended thinkingNo
Released2025-09
Knowledge cutoff2025-06
ProviderMistral

Verified 2026-08-14 — source.

Where does Codestral rank?

32nd-largest context window of 42 current models10th-cheapest of 42 current models12th-fastest measured, at 118 tok/s

What are Codestral's strengths?

  • Code-specialised training
  • Fast, low-cost completions
  • Wide language coverage

What else should you know about Codestral?

Price
$0.45/M blended tokens
Provider
Served by Mistral
Best for
#9 for Structured Data Extraction
Speed
118 tok/s measured

What are common questions about Codestral?

What is Codestral's context window?

Codestral has a 256K-token context window and a 33K-token max output — the 32nd-largest context of the 42 current models we track. Source: https://docs.mistral.ai/getting-started/models/, verified 2026-08-14.

Does Codestral support vision or audio input?

No — Codestral is text-only as of 2026-08-14.

Does Codestral have a reasoning or extended-thinking mode?

No — Codestral does not expose a separate reasoning/extended-thinking mode.

When was Codestral released, and what is its knowledge cutoff?

Codestral was released 2025-09 with a knowledge cutoff of 2025-06.

How much does Codestral cost, and who provides it?

Codestral is served by Mistral at $0.45/M blended tokens (3:1 input:output) — the 10th-cheapest of 42 current models. Full pricing breakdown: /llm-api-pricing/codestral.

Try Codestral for free

Run real prompts against Codestral and every other model on this site in one workspace.

Try Codestral Free