Microsoft · 3.84B
Can I run Phi-4 Mini 3.8B Instruct locally?
Phi-4 Mini 3.8B Instruct needs about 4.1 GB at Q4_K_M with 8K context, so it fits fully on a 6 GB GPU.
Model facts
| Parameters | 3.84B params |
|---|---|
| Max context | 131,072 tokens |
| Attention | 32 full-attention layers, 8 KV heads (grouped-query) |
| Good for | Chat |
| Source | microsoft/Phi-4-mini-instruct |
Quick answer
Smallest GPU that holds it fully: 6 GB (Q4_K_M, 8K context)
Consumer GPUs that fit it fully: 39 of 39
With partial offload (32 GB RAM): 0 more
Fitting fully is what you want: offloading works, but generation speed drops to what your system RAM can deliver.
Memory needed by quant and context
Total estimate: weights + KV cache (FP16) + runtime buffer. Pick a row whose number is below your VRAM (or about 2/3 of a Mac's memory). To try another quant, context length or KV cache precision, open Phi-4 Mini 3.8B Instruct in the VRAM calculator.
- Q8_05.7 GB
- Q6_K4.9 GB
- Q5_K_M4.5 GB
- Q4_K_M4.1 GB
- Q3_K_M3.7 GB
Dashed lines mark common card or memory sizes in GB.
| Quant | 4K ctx | 8K ctx | 32K ctx | 128K ctx |
|---|---|---|---|---|
| Q8_0 | 5.2 GB | 5.7 GB | 8.7 GB | 20.7 GB |
| Q6_K | 4.4 GB | 4.9 GB | 7.9 GB | 19.9 GB |
| Q5_K_M | 4.0 GB | 4.5 GB | 7.5 GB | 19.5 GB |
| Q4_K_M | 3.6 GB | 4.1 GB | 7.1 GB | 19.1 GB |
| Q3_K_M | 3.2 GB | 3.7 GB | 6.7 GB | 18.7 GB |
GPUs that run Phi-4 Mini 3.8B Instruct
At 8K context with 32 GB of DDR5 system RAM for offload. Speeds are estimates.
| GPU | VRAM | Verdict | Quant | Speed (est.) |
|---|---|---|---|---|
| GeForce RTX 5090 | 32 GB | Fits on GPU | Q8_0 | 185–280 tok/s |
| GeForce RTX 5080 | 16 GB | Fits on GPU | Q8_0 | 100–160 tok/s |
| GeForce RTX 5070 Ti | 16 GB | Fits on GPU | Q8_0 | 95–150 tok/s |
| GeForce RTX 5070 | 12 GB | Fits on GPU | Q8_0 | 70–110 tok/s |
| GeForce RTX 5060 Ti 16GB | 16 GB | Fits on GPU | Q8_0 | 50–75 tok/s |
| GeForce RTX 5060 Ti 8GB | 8 GB | Fits on GPU | Q8_0 | 50–75 tok/s |
| GeForce RTX 5060 | 8 GB | Fits on GPU | Q8_0 | 50–75 tok/s |
| GeForce RTX 4090 | 24 GB | Fits on GPU | Q8_0 | 105–165 tok/s |
| GeForce RTX 4080 Super | 16 GB | Fits on GPU | Q8_0 | 80–125 tok/s |
| GeForce RTX 4080 | 16 GB | Fits on GPU | Q8_0 | 75–120 tok/s |
| GeForce RTX 4070 Ti Super | 16 GB | Fits on GPU | Q8_0 | 70–110 tok/s |
| GeForce RTX 4070 Ti | 12 GB | Fits on GPU | Q8_0 | 55–85 tok/s |
| GeForce RTX 4070 Super | 12 GB | Fits on GPU | Q8_0 | 55–85 tok/s |
| GeForce RTX 4070 | 12 GB | Fits on GPU | Q8_0 | 55–85 tok/s |
| GeForce RTX 4060 Ti 16GB | 16 GB | Fits on GPU | Q8_0 | 30–50 tok/s |
| GeForce RTX 4060 Ti 8GB | 8 GB | Fits on GPU | Q8_0 | 30–50 tok/s |
| GeForce RTX 4060 | 8 GB | Fits on GPU | Q8_0 | 30–45 tok/s |
| GeForce RTX 3090 Ti | 24 GB | Fits on GPU | Q8_0 | 105–165 tok/s |
| GeForce RTX 3090 | 24 GB | Fits on GPU | Q8_0 | 100–155 tok/s |
| GeForce RTX 3080 Ti | 12 GB | Fits on GPU | Q8_0 | 95–150 tok/s |
| GeForce RTX 3080 10GB | 10 GB | Fits on GPU | Q8_0 | 80–125 tok/s |
| GeForce RTX 3070 | 8 GB | Fits on GPU | Q8_0 | 50–75 tok/s |
| GeForce RTX 3060 Ti | 8 GB | Fits on GPU | Q8_0 | 50–75 tok/s |
| GeForce RTX 3060 12GB | 12 GB | Fits on GPU | Q8_0 | 40–60 tok/s |
| GeForce RTX 2080 Ti | 11 GB | Fits on GPU | Q8_0 | 65–105 tok/s |
| GeForce RTX 2060 6GB | 6 GB | Fits on GPU | Q6_K | 45–70 tok/s |
| Radeon RX 9070 XT | 16 GB | Fits on GPU | Q8_0 | 55–95 tok/s |
| Radeon RX 9070 | 16 GB | Fits on GPU | Q8_0 | 55–95 tok/s |
| Radeon RX 9060 XT 16GB | 16 GB | Fits on GPU | Q8_0 | 25–50 tok/s |
| Radeon RX 7900 XTX | 24 GB | Fits on GPU | Q8_0 | 80–140 tok/s |
| Radeon RX 7900 XT | 20 GB | Fits on GPU | Q8_0 | 70–115 tok/s |
| Radeon RX 7900 GRE | 16 GB | Fits on GPU | Q8_0 | 50–85 tok/s |
| Radeon RX 7800 XT | 16 GB | Fits on GPU | Q8_0 | 55–90 tok/s |
| Radeon RX 7700 XT | 12 GB | Fits on GPU | Q8_0 | 35–65 tok/s |
| Radeon RX 7600 | 8 GB | Fits on GPU | Q8_0 | 25–45 tok/s |
| Radeon RX 6800 XT | 16 GB | Fits on GPU | Q8_0 | 45–75 tok/s |
| Radeon RX 6700 XT | 12 GB | Fits on GPU | Q8_0 | 35–55 tok/s |
| Arc B580 | 12 GB | Fits on GPU | Q8_0 | 35–60 tok/s |
| Arc A770 16GB | 16 GB | Fits on GPU | Q8_0 | 40–70 tok/s |
Macs and unified-memory PCs
The smallest memory configuration that holds it fully at 8K context.
| Chip | Memory needed | Quant | Speed (est.) |
|---|---|---|---|
| Apple M1 | 8 GB | Q6_K | 6–14 tok/s |
| Apple M1 Pro | 16 GB | Q8_0 | 15–30 tok/s |
| Apple M1 Max | 32 GB | Q8_0 | 30–65 tok/s |
| Apple M1 Ultra | 64 GB | Q8_0 | 60–125 tok/s |
| Apple M2 | 8 GB | Q6_K | 9–20 tok/s |
| Apple M2 Pro | 16 GB | Q8_0 | 15–30 tok/s |
| Apple M2 Max | 32 GB | Q8_0 | 30–65 tok/s |
| Apple M2 Ultra | 64 GB | Q8_0 | 60–125 tok/s |
| Apple M3 | 8 GB | Q6_K | 9–20 tok/s |
| Apple M3 Pro | 18 GB | Q8_0 | 11–25 tok/s |
| Apple M3 Max (40-core GPU) | 48 GB | Q8_0 | 30–65 tok/s |
| Apple M3 Ultra | 96 GB | Q8_0 | 60–130 tok/s |
| Apple M4 | 16 GB | Q8_0 | 9–19 tok/s |
| Apple M4 Pro | 24 GB | Q8_0 | 20–45 tok/s |
| Apple M4 Max (16-core CPU) | 48 GB | Q8_0 | 40–85 tok/s |
| Apple M5 | 16 GB | Q8_0 | 12–25 tok/s |
| AMD Ryzen AI Max+ 395 | 64 GB | Q8_0 | 20–40 tok/s |
| NVIDIA DGX Spark | 128 GB | Q8_0 | 30–45 tok/s |
Parameter count and architecture come from the model's Hugging Face page and config.json. Memory and speed are calculated; see methodology.