# Phi-4: hardware requirements
> Phi-4 (Microsoft) is a 14.7B dense model with a 16K-token context window, released under the MIT license. It needs about 12GB of memory at Q4_K_M with 8K context.
Phi-4 is Microsoft's 14B dense model, trained heavily on synthetic data to punch above its size on math and reasoning. Microsoft has not released a Phi-5, so it remains the current base model of the Phi line, alongside reasoning-tuned variants such as Phi-4-reasoning. At Q4_K_M it needs about 12GB with 8K context, which is tight on a 12GB card and comfortable on 16GB. Its 16K context limit and narrow knowledge make Qwen3.5 9B or gpt-oss-20b better general picks in 2026.

## Recommended hardware
- **Minimum GPU:** RTX 3060 12GB (12GB), Q3_K_M, ~34 tokens/sec
- **Best value:** RTX 3060 12GB (12GB), Q3_K_M, ~34 tokens/sec
- **Fastest single GPU:** RTX 5090 (32GB), Q8_0, ~84 tokens/sec
- **Mac / unified memory:** Ryzen AI Max+ 395 (128GB), Q8_0, ~12 tokens/sec

## Memory by quantization
| Quant | Weights | Total @ 8K ctx | Total @ 32K ctx |
| --- | --- | --- | --- |
| Q2_K | 5.6GB | 8.0GB | - |
| Q3_K_M | 7.3GB | 9.8GB | - |
| Q4_K_M | 9.1GB | 11.6GB | - |
| Q5_K_M | 10.6GB | 13.2GB | - |
| Q6_K | 12.3GB | 15.0GB | - |
| Q8_0 | 15.6GB | 18.3GB | - |
| BF16 | 29.3GB | 32.5GB | - |

## GPUs that run it fully in memory (fastest first)
| GPU | Memory | Quant | Speed | Price |
| --- | --- | --- | --- | --- |
| RTX 5090 | 32GB | Q8_0 | ~84 tok/s | ~$4,300 |
| RTX PRO 6000 | 96GB | Q8_0 | ~84 tok/s | ~$16,000 |
| RTX 5070 | 12GB | Q3_K_M | ~69 tok/s | ~$800 |
| RTX 5080 | 16GB | Q5_K_M | ~67 tok/s | ~$1,600 |
| RTX PRO 5000 72GB | 72GB | Q8_0 | ~65 tok/s | ~$9,100 |
| RTX 5070 Ti | 16GB | Q5_K_M | ~63 tok/s | ~$1,200 |
| RTX 4070 | 12GB | Q3_K_M | ~52 tok/s | ~$560 used |
| RTX 4080 Super | 16GB | Q5_K_M | ~52 tok/s | ~$1,150 used |
| RTX 4090 | 24GB | Q8_0 | ~49 tok/s | ~$2,500 used |
| RTX 4070 Ti Super | 16GB | Q5_K_M | ~48 tok/s | ~$900 used |
| RTX 6000 Ada | 48GB | Q8_0 | ~47 tok/s | ~$4,750 used |
| RTX 3090 | 24GB | Q8_0 | ~41 tok/s | ~$1,050 used |
| M5 Ultra 512GB | 512GB | Q8_0 | ~41 tok/s | n/a |
| M5 Ultra 256GB | 256GB | Q8_0 | ~41 tok/s | ~$9,499 |
| RX 7900 XTX | 24GB | Q8_0 | ~38 tok/s | ~$1,050 used |
| RX 9070 XT | 16GB | Q5_K_M | ~37 tok/s | ~$800 |
| V100 32GB | 32GB | Q8_0 | ~36 tok/s | ~$700 used |
| RTX 3060 12GB | 12GB | Q3_K_M | ~34 tok/s | ~$270 used |
| RTX A6000 | 48GB | Q8_0 | ~34 tok/s | ~$4,400 used |
| RTX 5060 Ti 16GB | 16GB | Q5_K_M | ~33 tok/s | ~$620 |
| Arc B580 | 12GB | Q3_K_M | ~32 tok/s | ~$330 |
| MI50 32GB | 32GB | Q8_0 | ~28 tok/s | ~$600 used |
| M3 Ultra 512GB | 512GB | Q8_0 | ~28 tok/s | $9,499 MSRP |
| R9700 | 32GB | Q8_0 | ~26 tok/s | ~$1,800 |
| M5 Max 128GB | 128GB | Q8_0 | ~25 tok/s | ~$5,100 |

## How to run it
- Ollama: `ollama run phi4:14b`
- llama.cpp: `llama-server -hf bartowski/phi-4-GGUF:Q4_K_M -c 8192 -ngl 99`
- MLX (Mac): `mlx_lm.chat --model mlx-community/phi-4-4bit`
- Weights: https://huggingface.co/microsoft/phi-4

## Strengths
- Strong math and logic for a 14B non-reasoning model
- Dense and simple to run in every runtime
- MIT license

## Weaknesses
- 16K context window
- Narrow world knowledge and weak creative writing
- Text only, with no reasoning mode in the base model
- Outclassed by smaller 2026 models such as Qwen3.5 9B
Full page: https://llamabuilds.ai/models/phi-4 · Hardware guide: https://llamabuilds.ai/models/phi-4/requirements

---
Source: https://llamabuilds.ai/models/phi-4 · Updated October 14, 2026 · Llama Builds. Speeds marked ~ are estimates from our bandwidth model (https://llamabuilds.ai/methodology); measured results are labeled as such.
