Qwen · text

Qwen3-4B-Base

Qwen/Qwen3-4B-Base

Qwen3-4B-Base at Q4_K_M is exactly 2,496,703,776 bytes (2.33 GiB / 2.50 GB) — an effective 4.965 bits per weight, not the nominal 4. Its KV cache at 32K is 4.50 GiB.

From the file· summed from 1 file(s)From the file· KV per layer
Parameters
4.0B
Architecture
qwen3
36 layers
Context
32,768
native (config.json)
License
apache-2.0

Shipped quantizations

exact bytes, summed from published files
QuantSizeExact bytesEffective bpwTensorsPublisher
IQ2_M1.41 GiB1,512,983,5523.009liodon-ai
Q2_K1.67 GiB1,796,334,6243.573QuantFactory
IQ3_M1.83 GiB1,962,895,8723.904liodon-ai
Q3_K_S1.91 GiB2,053,266,1444.084QuantFactory
Q3_K_M2.09 GiB2,241,886,9444.459QuantFactory
IQ4_XS2.11 GiB2,270,751,2324.516liodon-ai
Q3_K_L2.24 GiB2,406,054,6244.785QuantFactory
Q4_K_M2.33 GiB2,496,703,7764.965Qwen
Q4_K_M2.33 GiB2,497,280,5124.967liodon-ai
Q4_02.41 GiB2,587,383,3605.146QuantFactory
Q4_K_S2.42 GiB2,601,145,9205.173QuantFactory
Q4_K_M2.53 GiB2,715,117,1205.400QuantFactory
Q5_02.63 GiB2,823,134,4965.615Qwen
Q4_12.64 GiB2,838,732,6405.646QuantFactory
Q5_K_M2.69 GiB2,888,936,7365.746Qwen
Q5_K_M2.69 GiB2,889,513,4725.747liodon-ai
Q5_K_S2.88 GiB3,090,081,9206.146QuantFactory
Q5_02.88 GiB3,090,081,9206.146QuantFactory
Q5_K_M2.94 GiB3,155,884,1606.277QuantFactory
Q6_K3.08 GiB3,305,684,2566.574Qwen
Q6_K3.08 GiB3,306,260,9926.576liodon-ai
Q5_13.11 GiB3,341,431,2006.646QuantFactory
Q6_K3.38 GiB3,624,199,1687.208QuantFactory
Q8_03.99 GiB4,279,660,2248.511Qwen
Q8_03.99 GiB4,280,404,9928.513liodon-ai
Q8_04.37 GiB4,692,212,3529.332QuantFactory
F167.50 GiB8,049,889,82416.010Qwen

KV cache by context

computed per layer
ContextKV cache (f16)Flat formulaOverstated byFull / windowed / recurrent
4,0960.56 GiB0.56 GiB36 / 0 / 0
8,1921.13 GiB1.13 GiB36 / 0 / 0
16,3842.25 GiB2.25 GiB36 / 0 / 0
32,7684.50 GiB4.50 GiB36 / 0 / 0
65,5369.00 GiB9.00 GiB36 / 0 / 0
131,07218.00 GiB18.00 GiB36 / 0 / 0

Compare with

same modality, comparable size

Will it run on your card?

full quant x context sweep

Why other calculators give a different number

A parameters × bits ÷ 8 estimate puts Q4_K_M at roughly 2.11 GiB. The real file is 2.33 GiB, because a quantization is a mixture and some tensors are always kept at higher precision.

Architecture

from config.json
Layers
36
Attention heads
32
KV heads
8
Head dim
128
Hidden size
2560
Vocab
151,936
Sliding window
none
SWA period
MLA
no
Experts
Experts per token
use_sliding_window
false

Questions people ask

How much VRAM does Qwen3-4B-Base need?
Q4_K_M is exactly 2,496,703,776 bytes (2.33 GiB) in weights. Add the KV cache, which depends on your context length, plus roughly half a gigabyte of runtime overhead.
How large is Qwen3-4B-Base's KV cache?
4.50 GiB at 32K context with an f16 cache, computed per layer. Quantizing the cache to q8_0 roughly halves it, which is often the difference between a context length fitting and not.
Which quantization of Qwen3-4B-Base should I use?
Q4_K_M is the usual default. Pick the largest quantization that fits your card at the context you actually need — the table above gives exact sizes for every one published.