Codestral 2508
VerifiedOpen-weight multimodal model for advanced coding and file tasks.
About Codestral 2508
Codestral 2508 combines multimodal capabilities with a large context window to handle extended inputs across text and file formats. Its open-weight release allows developers to inspect and adapt the model for specialized environments.
The architecture emphasizes integration of visual and textual data for coding assistance and file analysis. Typical usage includes code generation, repository understanding, and processing lengthy technical documents.
Capabilities
How Codestral 2508 compares
Codestral 2508 (striped bar) vs other multimodal on intelligence, speed and price.
Price
USD per 1M output tokens · Lower is better · Codestral 2508 ranks #23 of 110
Sources: Artificial Analysis (intelligence, speed) · OpenRouter (price).
Best for
Long-context code analysis
Codestral 2508 processes up to 256000 tokens, making it suitable for reviewing entire codebases or lengthy technical documents in a single pass.
Multimodal programming tasks
As a multimodal model from Mistral, it handles combined text, code, and image inputs for scenarios like interpreting UI screenshots alongside source code.
Technical documentation generation
The model excels at producing detailed code explanations and documentation when given extensive multimodal project materials.
Strengths & limitations
Strengths
- +Strong specialization in coding workflows
- +Effective handling of large codebases
- +Broad language coverage for developers
Limitations
- –Narrow focus on code over general tasks
- –Text and file modalities only
- –Less suitable for non-technical queries
Cost calculator
Estimate what Codestral 2508 would cost for your usage.
Based on Codestral 2508's $0.30/1M input · $0.90/1M output. Estimate only — actual cost varies by provider and caching.
Quick start
OpenRouter's API is OpenAI-compatible — most SDKs work by just swapping the base URL. Only the model slug changes between models.
import OpenAI from "openai";
const client = new OpenAI({
baseURL: "https://openrouter.ai/api/v1",
apiKey: process.env.OPENROUTER_API_KEY,
});
const completion = await client.chat.completions.create({
model: "mistralai/codestral-2508",
messages: [{ role: "user", content: "Hello!" }],
});
console.log(completion.choices[0].message.content);Model slug: mistralai/codestral-2508
Editor's verdict
Codestral 2508 is Mistral's open-weight multimodal with a 256K-token context window.
At $0.90 per 1M output tokens, it is very cost-efficient for its class.
As an open-weight model you can self-host it or call it through a hosted API.
Best suited to strong specialization in coding workflows and effective handling of large codebases.
Frequently asked questions
Codestral 2508 supports a context length of 256000 tokens.
User reviews
Real, verified reviews from the community shape this model's rating.
Loading reviews…