How to Deploy Qwen3 8B Locally
Qwen3 8B is an 8B dense model that Qwen released in April 2025, and /think and /no_think in your prompt toggle thinking turn by turn. With room for 40K of context, 4-bit takes about 12.1 GB, a snug fit for a 12GB card. For a new setup, we recommend going straight to Qwen3.5 9B: VRAM is basically the same, context grows from 40K to 256K, and it understands images and video too.
Qwen3 8B details
- Min VRAM at 4-bit8 GB · 8K
- Parameters8.2B
- Max context40K
- Architecture
- Dense
- License
- Apache-2.0
- Launch date
- Apr 27, 2025
- Vendor
- Alibaba
- Hugging Face repo
- Qwen/Qwen3-8B
- GGUF repo
- Qwen/Qwen3-8B-GGUF
- NVFP4 repo (Blackwell)
- nvidia/Qwen3-8B-NVFP4
- MLX repo (Apple)
- Qwen/Qwen3-8B-MLX-4bit
- Ollama tag
- qwen3:8b
- Layers
- 36
- Hidden size
- 4,096
- KV heads
- 8
- Head dim
- 128
How much VRAM does Qwen3 8B need for local deployment?
| Quantization | WeightsGB | 8K contextGB | 32K contextGB | 40K context (max)GB |
|---|---|---|---|---|
| 1-bit | 2.4GGUF | 4.7 | 8.3 | 9.5 |
| 2-bit | 3.5GGUF | 5.8 | 9.4 | 10.6 |
| 3-bit | 4.3GGUF | 6.6 | 10.2 | 11.4 |
| 4-bit | 5GGUF | 7.3 | 10.9 | 12.1 |
| 5-bit | 5.9GGUF | 8.2 | 11.8 | 13 |
| 8-bit | 8.7GGUF | 11 | 14.6 | 15.8 |
| BF16/FP16 | 16.4GGUF | 18.7 | 22.3 | 23.5 |
Full calculation rules are on the Methodology page.
Can a single GPU run Qwen3 8B?
Yes, a 12GB card is enough, as long as you size for the full 40K context. In thinking mode it writes a long chain of reasoning before answering, and Qwen recommends leaving 32K of room for the reply, so sizing for 8K alone leaves you short; at 4-bit with the full 40K, it just fits on a 12GB card. With 16GB, 8-bit is the better pick: it still fits at full context and stays closer to the original, at about 35 tokens/s on an RTX 5060 Ti 16GB, while a 24GB RTX 3090 runs 8-bit twice as fast. For a new setup, Qwen3.5 9B needs about the same memory with far more context, so try it first.
| Device | Price | Speed t/s | Max context |
|---|---|---|---|
| $37024 listings | 136.4 | 40K | |
| $86958 listings | 75.1 | 40K | |
| $89518 listings | 136.4 | 40K | |
| Radeon RX 7900 XTX24 GB | $1,25029 listings | 143.7 | 40K |
| $1,799107 listings | 140.8 | 40K | |
| $3,75868 listings | 149.4 | 40K | |
| Ryzen AI Max+ 395 128GBWhole system · 128 GB | $4,46420 listings | 45 | 40K |
| $4,89916 listings | 119.8 | 40K | |
| Mac Studio M5 Ultra 96GBWhole system · 96 GB | $7,27412 listings | 174.1 | 40K |
| MacBook Pro M5 Max 128GBWhole system · 128 GB | $7,54920 listings | 99.1 | 40K |
| $8,24022 listings | 47.7 | 40K | |
| $8,395123 listings | 228.4 | 40K | |
| $22,50011 listings | 228.4 | 40K |
| Device | Price | Speed t/s | Max context |
|---|---|---|---|
| $37024 listings | 105.2 | 40K | |
| $86958 listings | 56.6 | 40K | |
| $89518 listings | 105.2 | 40K | |
| Radeon RX 7900 XTX24 GB | $1,25029 listings | 111.1 | 40K |
| $1,799107 listings | 108.8 | 40K | |
| $3,75868 listings | 115.8 | 40K | |
| Ryzen AI Max+ 395 128GBWhole system · 128 GB | $4,46420 listings | 33.5 | 40K |
| $4,89916 listings | 91.8 | 40K | |
| Mac Studio M5 Ultra 96GBWhole system · 96 GB | $7,27412 listings | 136.3 | 40K |
| MacBook Pro M5 Max 128GBWhole system · 128 GB | $7,54920 listings | 75.3 | 40K |
| $8,24022 listings | 35.6 | 40K | |
| $8,395123 listings | 182.8 | 40K | |
| $22,50011 listings | 182.8 | 40K |
| Device | Price | Speed t/s | Max context |
|---|---|---|---|
| $37024 listings | 67.3 | 40K | |
| $86958 listings | 35.1 | 40K | |
| $89518 listings | 67.3 | 40K | |
| Radeon RX 7900 XTX24 GB | $1,25029 listings | 71.3 | 40K |
| $1,799107 listings | 69.7 | 40K | |
| $3,75868 listings | 74.5 | 40K | |
| Ryzen AI Max+ 395 128GBWhole system · 128 GB | $4,46420 listings | 20.5 | 40K |
| $4,89916 listings | 58.2 | 40K | |
| Mac Studio M5 Ultra 96GBWhole system · 96 GB | $7,27412 listings | 88.8 | 40K |
| MacBook Pro M5 Max 128GBWhole system · 128 GB | $7,54920 listings | 47.3 | 40K |
| $8,24022 listings | 21.8 | 40K | |
| $8,395123 listings | 122.5 | 40K | |
| $22,50011 listings | 122.5 | 40K |
Only common GPUs and systems are listed, one set for models under 50B and another for larger ones, sorted by price from low to high.
What to know before running Qwen3 8B locally
Thinking switches
Thinking is on by default, and there are two ways to turn it off.
enable_thinking=Falseis a hard switch that suppresses thinking output entirely; alternatively, add /think or /no_think to your prompt to switch turn by turn. Qwen dropped official support for that second, soft switch starting with Qwen3.5.Official sampling parameters
Thinking mode:
temperature0.6,top_p0.95,top_k20,min_p0; Qwen stresses not to use greedy decoding (always picking the most likely token), or the model tends to repeat endlessly. Non-thinking mode:temperature0.7,top_p0.8,top_k20,min_p0.Going beyond 32K of context
Its native context is only 32K, extendable to 131K with YaRN. But Qwen notes that YaRN in open-source frameworks uses a fixed scaling factor, which can hurt results on short text, so only enable it when you actually need to process long documents. In llama-server, just add the rope scaling flags; if you change the config file instead, you need to regenerate the GGUF.
Which quantization to pick
Qwen's official repository provides GGUFs directly, and the Ollama tag is qwen3:8b. 4-bit is about 5.0 GB and 8-bit about 8.7 GB, only 3.7 GB apart, so use 8-bit if you have the VRAM.
Launch commands
Ollama
- Windows
- macOS
- Linux
ollama run qwen3:8bllama.cpp
- NVIDIA
- AMD
- Mac
- CPU
llama-server -hf Qwen/Qwen3-8B-GGUF:Q4_K_M -c 8192
vLLM
- Linux
- NVIDIA
- AMD
vllm serve Qwen/Qwen3-8BBlackwell GPUs (RTX 50 series, RTX PRO 6000, B200) run NVFP4 weights natively, at about 30% of the original size.
vllm serve nvidia/Qwen3-8B-NVFP4MLX
- Apple Silicon
On a Mac, pip install mlx-lm first; this command downloads the MLX weights from Hugging Face and starts an OpenAI-compatible server.
mlx_lm.server --model Qwen/Qwen3-8B-MLX-4bitFile names follow that week's model-library snapshot; the definitions are in the methodology. Methodology
Other models in the Qwen family
| Model | Total params | Active params | 4-bit size |
|---|---|---|---|
| 9.7B | 9.7B | 5.7 GB | |
| 27.8B | 27.8B | 16.8 GB | |
| 27.8B | 27.8B | 16.5 GB | |
| 32.8B | 32.8B | 19.8 GB | |
| 36B | 3B | 22.1 GB | |
| 176B | 6B | 111.3 GB | |
| 2,446B | 95B | 1,310.9 GB |