Mistral Codestral 22B
Mistral dedicated generative programming model with fill-in-the-middle (FIM) mastery.
Mistral Codestral 22B is an open-weights generative model tailored specifically for code generation tasks. Trained on over 80 programming languages, it excels at fill-in-the-middle code completion, unit testing, and refactoring.
⚡ Key Architectural Strengths
VRAM & Quantization Memory Footprint
Exact file weights, minimum VRAM to boot, and recommended headroom for extended context windows.
| Quantization Tier | Weight Size | Min VRAM/RAM | Recommended VRAM | Recommended Use Case |
|---|---|---|---|---|
| Q4_K_M (Recommended) | 13.5 GB | 15 GB | 16 GB | Fits 16GB VRAM GPU (RTX 4060 Ti 16GB / 4080) or 18GB+ Mac. |
| Q8_0 (High Precision) | 23.8 GB | 26 GB | 28 GB | Requires 32GB+ Unified Memory or dual GPU system. |
| BF16 / FP16 (Unquantized) | 44.5 GB | 48 GB | 52 GB | Unquantized weights. |
⚡ Need to calculate exact KV Cache with 16k or 32k context?
Simulate exact VRAM allocations across various context lengths and precision depths.
1-Click Local Run Commands
Copy and paste directly into your terminal or local server engine.
ollama run codestral:22blms load mistralai/Codestral-22B-v0.1-GGUFvllm serve mistralai/Codestral-22B-v0.1 --dtype auto./llama-cli -m Codestral-22B-v0.1-Q4_K_M.gguf -p "Write an asynchronous task worker" -c 8192Hardware Compatibility & Speed Estimates
Estimated against 55+ Apple Silicon, Qualcomm, and NVIDIA hardware profiles.
| Device / Hardware Name | Platform | RAM/VRAM | Fit Status | Est. Tokens/Sec | Notes |
|---|---|---|---|---|---|
| Apple MacBook Air 13-inch (M4, 2025) | macOS | 16 GB | Unsupported | — | Not enough memory to load the 4-bit weights (~13.5GB) plus overhead. |
| HP Omnibook 5 OLED | Windows ARM | 32 GB | Comfortable | 6.5 t/s | Fits fully in GPU-usable memory (~19.2GB) with room for a longer context. Speed is a bandwidth-based estimate. |
| Apple MacBook Pro 16-inch (M4 Max) | macOS | 64 GB | Comfortable | 26.3 t/s | Fits fully in GPU-usable memory (~48GB) with room for a longer context. Speed is a bandwidth-based estimate. |
| Apple Mac mini (M4, 16GB) | macOS | 16 GB | Unsupported | — | Not enough memory to load the 4-bit weights (~13.5GB) plus overhead. |
| Apple Mac mini (M4 Pro, 24GB) | macOS | 24 GB | Comfortable | 13.1 t/s | Fits fully in GPU-usable memory (~16.1GB) with room for a longer context. Speed is a bandwidth-based estimate. |
| Apple Mac Studio (M2 Ultra 192GB) | macOS | 192 GB | Comfortable | 38.5 t/s | Fits fully in GPU-usable memory (~144GB) with room for a longer context. Speed is a bandwidth-based estimate. |
| Microsoft Surface Laptop 7 | Windows ARM | 16 GB | Unsupported | — | Not enough memory to load the 4-bit weights (~13.5GB) plus overhead. |
| Lenovo ThinkPad T14s Gen 5 (Snapdragon) | Windows ARM | 32 GB | Comfortable | 6.5 t/s | Fits fully in GPU-usable memory (~19.2GB) with room for a longer context. Speed is a bandwidth-based estimate. |
| ASUS Zenbook S 16 (Ryzen AI 9 HX 370) | Windows x86 | 32 GB | Comfortable | 5.8 t/s | Fits fully in GPU-usable memory (~19.2GB) with room for a longer context. Speed is a bandwidth-based estimate. |
| Dell XPS 13 (Intel Core Ultra 7 258V) | Windows x86 | 32 GB | Comfortable | 6.5 t/s | Fits fully in GPU-usable memory (~19.2GB) with room for a longer context. Speed is a bandwidth-based estimate. |
| ASUS ROG Zephyrus G16 (RTX 4070 Laptop) | Windows x86 | 32 GB | CPU Offload | 4.3 t/s | Exceeds the 8GB of VRAM, so some layers run from system RAM, which is much slower. Estimate only. |
| Razer Blade 16 (RTX 4090 Mobile 16GB) | Windows x86 | 32 GB | Comfortable | 27.7 t/s | Fits fully in VRAM (~16GB) with room for a longer context. Speed is a bandwidth-based estimate. |
| Framework Laptop 13 (Ryzen 7 7840U) | Linux | 64 GB | Comfortable | 4.3 t/s | Fits fully in GPU-usable memory (~38.4GB) with room for a longer context. Speed is a bandwidth-based estimate. |
| Lenovo Legion Pro 7i (RTX 4080 12GB) | Windows x86 | 32 GB | CPU Offload | 4.3 t/s | Exceeds the 12GB of VRAM, so some layers run from system RAM, which is much slower. Estimate only. |
| Dell XPS 14 (Core Ultra 7) | Windows x86 | 16 GB | Unsupported | — | Not enough memory to load the 4-bit weights (~13.5GB) plus overhead. |
| Lenovo ThinkPad E14 (Budget Setup) | Windows x86 | 8 GB | Unsupported | — | Not enough memory to load the 4-bit weights (~13.5GB) plus overhead. |
| Acer Swift 14 AI (Snapdragon X Plus) | Windows ARM | 16 GB | Unsupported | — | Not enough memory to load the 4-bit weights (~13.5GB) plus overhead. |
| Custom Workstation PC (RTX 4090 24GB) | Linux | 64 GB | Comfortable | 48.5 t/s | Fits fully in VRAM (~24GB) with room for a longer context. Speed is a bandwidth-based estimate. |
| Legacy Budget Desktop (GTX 1650 4GB) | Windows x86 | 16 GB | CPU Offload | 2.1 t/s | Exceeds the 4GB of VRAM, so some layers run from system RAM, which is much slower. Estimate only. |
| Apple MacBook Pro 16-inch (M4 Max 128GB) | macOS | 128 GB | Comfortable | 26.3 t/s | Fits fully in GPU-usable memory (~96GB) with room for a longer context. Speed is a bandwidth-based estimate. |
| Apple MacBook Pro 14-inch (M4 Pro 48GB) | macOS | 48 GB | Comfortable | 13.1 t/s | Fits fully in GPU-usable memory (~36GB) with room for a longer context. Speed is a bandwidth-based estimate. |
| Apple MacBook Pro 14-inch (M4 Base 24GB) | macOS | 24 GB | Comfortable | 5.8 t/s | Fits fully in GPU-usable memory (~16.1GB) with room for a longer context. Speed is a bandwidth-based estimate. |
| Apple MacBook Air 15-inch (M3 16GB) | macOS | 16 GB | Unsupported | — | Not enough memory to load the 4-bit weights (~13.5GB) plus overhead. |
| Apple MacBook Air 13-inch (M3 8GB Base) | macOS | 8 GB | Unsupported | — | Not enough memory to load the 4-bit weights (~13.5GB) plus overhead. |
| Apple MacBook Air 13-inch (M2 16GB) | macOS | 16 GB | Unsupported | — | Not enough memory to load the 4-bit weights (~13.5GB) plus overhead. |
| Apple MacBook Air (M1 16GB Legacy) | macOS | 16 GB | Unsupported | — | Not enough memory to load the 4-bit weights (~13.5GB) plus overhead. |
| Apple MacBook Pro 16-inch (M3 Max 128GB) | macOS | 128 GB | Comfortable | 19.3 t/s | Fits fully in GPU-usable memory (~96GB) with room for a longer context. Speed is a bandwidth-based estimate. |
| Apple MacBook Pro 14-inch (M3 Pro 36GB) | macOS | 36 GB | Comfortable | 7.2 t/s | Fits fully in GPU-usable memory (~24.1GB) with room for a longer context. Speed is a bandwidth-based estimate. |
| Apple Mac Studio (M1 Ultra 64GB) | macOS | 64 GB | Comfortable | 38.5 t/s | Fits fully in GPU-usable memory (~48GB) with room for a longer context. Speed is a bandwidth-based estimate. |
| Samsung Galaxy Book4 Edge (Snapdragon X Elite) | Windows ARM | 16 GB | Unsupported | — | Not enough memory to load the 4-bit weights (~13.5GB) plus overhead. |
| Lenovo Yoga Slim 7x Copilot+ | Windows ARM | 32 GB | Comfortable | 6.5 t/s | Fits fully in GPU-usable memory (~19.2GB) with room for a longer context. Speed is a bandwidth-based estimate. |
| Microsoft Surface Pro 11 Copilot+ (OLED) | Windows ARM | 32 GB | Comfortable | 6.5 t/s | Fits fully in GPU-usable memory (~19.2GB) with room for a longer context. Speed is a bandwidth-based estimate. |
| Dell XPS 13 Copilot+ (Snapdragon X Elite) | Windows ARM | 16 GB | Unsupported | — | Not enough memory to load the 4-bit weights (~13.5GB) plus overhead. |
| Custom Workstation PC (RTX 4080 Super 16GB) | Linux / Windows | 32 GB | Comfortable | 35.4 t/s | Fits fully in VRAM (~16GB) with room for a longer context. Speed is a bandwidth-based estimate. |
| Custom AI Workstation (RTX 4070 Ti Super 16GB) | Linux / Windows | 32 GB | Comfortable | 32.4 t/s | Fits fully in VRAM (~16GB) with room for a longer context. Speed is a bandwidth-based estimate. |
| Desktop PC (RTX 4070 Super 12GB) | Windows / Linux | 32 GB | CPU Offload | 4.3 t/s | Exceeds the 12GB of VRAM, so some layers run from system RAM, which is much slower. Estimate only. |
| Budget AI Workstation (RTX 4060 Ti 16GB) | Linux / Windows | 32 GB | Comfortable | 13.9 t/s | Fits fully in VRAM (~16GB) with room for a longer context. Speed is a bandwidth-based estimate. |
| Mainstream Desktop (RTX 4060 8GB) | Windows / Linux | 32 GB | CPU Offload | 2.5 t/s | Exceeds the 8GB of VRAM, so some layers run from system RAM, which is much slower. Estimate only. |
| Used AI Powerhouse PC (RTX 3090 24GB) | Linux / Windows | 64 GB | Comfortable | 45.1 t/s | Fits fully in VRAM (~24GB) with room for a longer context. Speed is a bandwidth-based estimate. |
| Budget Workhorse PC (RTX 3060 12GB) | Windows / Linux | 16 GB | CPU Offload | 2.5 t/s | Exceeds the 12GB of VRAM, so some layers run from system RAM, which is much slower. Estimate only. |
| Lenovo Legion 5i (RTX 4060 Laptop 8GB) | Windows x86 | 16 GB | CPU Offload | 4.3 t/s | Exceeds the 8GB of VRAM, so some layers run from system RAM, which is much slower. Estimate only. |
| ASUS TUF Gaming A15 (RTX 4060 Laptop 8GB) | Windows x86 | 16 GB | CPU Offload | 4.3 t/s | Exceeds the 8GB of VRAM, so some layers run from system RAM, which is much slower. Estimate only. |
| Acer Predator Helios Neo 16 (RTX 4070 Laptop) | Windows x86 | 32 GB | CPU Offload | 4.3 t/s | Exceeds the 8GB of VRAM, so some layers run from system RAM, which is much slower. Estimate only. |
| HP Victus 16 (RTX 4050 Laptop 6GB) | Windows x86 | 16 GB | CPU Offload | 4.3 t/s | Exceeds the 6GB of VRAM, so some layers run from system RAM, which is much slower. Estimate only. |
| Dell Alienware m16 R2 (RTX 4070 8GB) | Windows x86 | 32 GB | CPU Offload | 4.3 t/s | Exceeds the 8GB of VRAM, so some layers run from system RAM, which is much slower. Estimate only. |
| ASUS ROG Zephyrus G16 (AMD AI 9 + RTX 4070) | Windows x86 | 32 GB | CPU Offload | 5.8 t/s | Exceeds the 8GB of VRAM, so some layers run from system RAM, which is much slower. Estimate only. |
| Lenovo IdeaPad Pro 5 (Ryzen 7 8845HS) | Windows / Linux | 32 GB | Comfortable | 4.9 t/s | Fits fully in GPU-usable memory (~19.2GB) with room for a longer context. Speed is a bandwidth-based estimate. |
| Custom Workstation PC (Radeon RX 7900 XTX 24GB) | Linux / Windows | 64 GB | Comfortable | 46.2 t/s | Fits fully in VRAM (~24GB) with room for a longer context. Speed is a bandwidth-based estimate. |
| Desktop PC (Radeon RX 7800 XT 16GB) | Linux / Windows | 32 GB | Comfortable | 30 t/s | Fits fully in VRAM (~16GB) with room for a longer context. Speed is a bandwidth-based estimate. |
| Budget Workstation (Radeon RX 7600 XT 16GB) | Linux / Windows | 32 GB | Comfortable | 13.9 t/s | Fits fully in VRAM (~16GB) with room for a longer context. Speed is a bandwidth-based estimate. |
| ASUS Zenbook S 14 (Lunar Lake Core Ultra 7) | Windows x86 | 32 GB | Comfortable | 6.5 t/s | Fits fully in GPU-usable memory (~19.2GB) with room for a longer context. Speed is a bandwidth-based estimate. |
| Lenovo Yoga Slim 7i Aura (Core Ultra 7 256V) | Windows x86 | 16 GB | Unsupported | — | Not enough memory to load the 4-bit weights (~13.5GB) plus overhead. |
| Custom PC (Intel Arc A770 16GB) | Linux / Windows | 32 GB | Comfortable | 27 t/s | Fits fully in VRAM (~16GB) with room for a longer context. Speed is a bandwidth-based estimate. |
| Homelab AI Server (Dual RTX 3090 48GB VRAM) | Linux (Ubuntu Server) | 128 GB | Comfortable | 45.1 t/s | Fits fully in VRAM (~48GB) with room for a longer context. Speed is a bandwidth-based estimate. |
| Lenovo ThinkPad X1 Carbon Gen 12 | Windows x86 / Linux | 32 GB | Comfortable | 5.8 t/s | Fits fully in GPU-usable memory (~19.2GB) with room for a longer context. Speed is a bandwidth-based estimate. |
| Flagship AI Workstation (RTX 5090 32GB) | Linux / Windows | 64 GB | Comfortable | 86.3 t/s | Fits fully in VRAM (~32GB) with room for a longer context. Speed is a bandwidth-based estimate. |
| High-End AI Rig (RTX 5080 16GB) | Linux / Windows | 64 GB | Comfortable | 46.2 t/s | Fits fully in VRAM (~16GB) with room for a longer context. Speed is a bandwidth-based estimate. |
| Next-Gen AI Laptop (Ryzen AI Max+ 395 128GB) | Linux / Windows | 128 GB | Comfortable | 12.3 t/s | Fits fully in GPU-usable memory (~96GB) with room for a longer context. Speed is a bandwidth-based estimate. |
| Apple Mac mini (M6, 16GB, 2026) | macOS | 16 GB | Unsupported | — | Not enough memory to load the 4-bit weights (~13.5GB) plus overhead. |
| Apple Mac mini (M6, 32GB, 2026) | macOS | 32 GB | Comfortable | 8.2 t/s | Fits fully in GPU-usable memory (~21.4GB) with room for a longer context. Speed is a bandwidth-based estimate. |
| Apple Mac mini (M5 Pro, 48GB, 2026) | macOS | 48 GB | Comfortable | 14.8 t/s | Fits fully in GPU-usable memory (~36GB) with room for a longer context. Speed is a bandwidth-based estimate. |
| Apple Mac mini (M5 Pro, 64GB, 2026) | macOS | 64 GB | Comfortable | 14.8 t/s | Fits fully in GPU-usable memory (~48GB) with room for a longer context. Speed is a bandwidth-based estimate. |
| Apple MacBook Pro 14-inch (M5, 32GB, 2025) | macOS | 32 GB | Comfortable | 7.4 t/s | Fits fully in GPU-usable memory (~21.4GB) with room for a longer context. Speed is a bandwidth-based estimate. |
| Apple Mac Studio (M5 Max, 128GB, 2026) | macOS | 128 GB | Comfortable | 29.6 t/s | Fits fully in GPU-usable memory (~96GB) with room for a longer context. Speed is a bandwidth-based estimate. |
| Apple Mac Studio (M5 Ultra, 256GB, 2026) | macOS | 256 GB | Comfortable | 57.8 t/s | Fits fully in GPU-usable memory (~192GB) with room for a longer context. Speed is a bandwidth-based estimate. |
| Apple Mac Studio (M5 Ultra, 512GB, 2026) | macOS | 512 GB | Comfortable | 57.8 t/s | Fits fully in GPU-usable memory (~384GB) with room for a longer context. Speed is a bandwidth-based estimate. |
| Apple Mac Studio (M3 Ultra, 512GB, 2025) | macOS | 512 GB | Comfortable | 39.4 t/s | Fits fully in GPU-usable memory (~384GB) with room for a longer context. Speed is a bandwidth-based estimate. |
| NVIDIA DGX Spark (GB10, 128GB) | DGX OS (Linux) | 128 GB | Comfortable | 13.1 t/s | Fits fully in GPU-usable memory (~110GB) with room for a longer context. Speed is a bandwidth-based estimate. |
| Desktop with NVIDIA RTX 5070 Ti (16GB) | Windows / Linux | 32 GB | Comfortable | 43.1 t/s | Fits fully in VRAM (~16GB) with room for a longer context. Speed is a bandwidth-based estimate. |
| Desktop with NVIDIA RTX 5060 Ti (16GB) | Windows / Linux | 32 GB | Comfortable | 21.6 t/s | Fits fully in VRAM (~16GB) with room for a longer context. Speed is a bandwidth-based estimate. |
| Desktop with AMD Radeon RX 9070 XT (16GB) | Windows / Linux | 32 GB | Comfortable | 30.8 t/s | Fits fully in VRAM (~16GB) with room for a longer context. Speed is a bandwidth-based estimate. |
| Desktop with AMD Radeon RX 9060 XT (16GB) | Windows / Linux | 32 GB | Comfortable | 15.4 t/s | Fits fully in VRAM (~16GB) with room for a longer context. Speed is a bandwidth-based estimate. |
| Desktop with Intel Arc B580 (12GB) | Windows / Linux | 32 GB | CPU Offload | 4.3 t/s | Exceeds the 12GB of VRAM, so some layers run from system RAM, which is much slower. Estimate only. |
| ASUS Zenbook A16 (Snapdragon X2 Elite Extreme, 48GB) | Windows 11 (ARM) | 48 GB | Comfortable | 11 t/s | Fits fully in GPU-usable memory (~28.8GB) with room for a longer context. Speed is a bandwidth-based estimate. |
| Snapdragon X2 Elite Laptop (32GB) | Windows 11 (ARM) | 32 GB | Comfortable | 7.3 t/s | Fits fully in GPU-usable memory (~19.2GB) with room for a longer context. Speed is a bandwidth-based estimate. |
Guides that cover Mistral Codestral 22B
Step-by-step setup, memory sizing and quantization choices from the BFWR guide library.
- Run Qwen Coding Models in VS Code & CursorA free local alternative to Copilot.Read the guide
- Best Local LLMs for CodingModels by VRAM tier, licence and scaffold support.Read the guide
- OpenCode With a Local LLM: Ollama, LM Studio and llama.cpp SetupThe 64K context it needs, memory per model, and safer permissions.Read the guide
Not sure if Mistral Codestral 22B fits your specific setup?
Our automated recommender calculates your exact hardware limits and suggests the best model weights for coding, reasoning, or fast conversational chat.