Best Local LLM for MacBook (2026): Qwen3.6 35B-A3B Wins
On a MacBook with 32GB or more, run Qwen3.6 35B-A3B. It is a mixture-of-experts model, so it generates fast even on the base M5 chip: 59.5 tok/s on a 32GB M5 in a community MLX test. Each RAM size has its own best pick, from Qwen3.5 9B on 16GB to gpt-oss 120B on 128GB. macOS lets the GPU use only 74-84% of your RAM, so the table below uses the measured limit, not the number on the box.
Running a local model on a MacBook?
Use the local model calculator first, then see our AI training options if you want help picking the model and quant for your Mac.
Bottom Line
- Best local LLM for a MacBook: Qwen3.6 35B-A3B. It runs on every MacBook with 32GB or more. The 4-bit file is 20.61 GiB.
- It is fast on every chip. Only 3B parameters are active per token. A 32GB base M5 generated 59.5 tok/s; a 48GB M5 Pro generated 97.0 tok/s (community-reported, oMLX, 1K context).
- Your Mac does not give the GPU all its RAM. The default Metal limit is 74% on 16GB and 24GB, rising to 84% on 128GB. Every verdict below uses the measured limit.
- RAM decides what fits. Bandwidth decides speed. The base M5 has 153 GB/s. The M5 Pro has 307 GB/s. The M5 Max has 460 or 614 GB/s.
- One pick per RAM size: 16GB Qwen3.5 9B · 24GB gpt-oss 20B · 32GB and 36GB Qwen3.6 35B-A3B · 48GB Qwen3.6 35B-A3B at 8 bits · 64GB Qwen3.8 27B at Q8_0 · 128GB gpt-oss 120B.
- On 64GB, gpt-oss 120B does not fit by default. Its 59.03 GiB file is 7.19 GiB over the 51.84 GiB limit.
- Buying today? Apple sells only M5 MacBooks. The best value for local AI is a 48GB M5 Pro: the 14-inch is $3,299 on apple.com (read 2026-10-20).
Ready to buy? See the tested hardware list with current prices.
Best Local LLM for Each MacBook RAM Size
Find your RAM in the first column. M4 owners use the same row as M5 owners: the limit depends on RAM, and the chip only changes speed.
| RAM | MacBooks Apple sells now | Default GPU limit | Best model | File | Context that fits | Measured speed |
|---|---|---|---|---|---|---|
| 16GB | Air M5, Pro M5 | 11.84 GiB (74%) | Qwen3.5 9B | Q8_0, 8.87 GiB | About 64K | Not measured on a MacBook |
| 24GB | Air M5, Pro M5, Pro M5 Pro | 17.76 GiB (74%) | gpt-oss 20B | MXFP4, 11.28 GiB | Full 128K | Not measured on 24GB; 92.36 tok/s on M4 Max 36GB (#15396) |
| 32GB | Air M5, Pro M5 | 24.96 GiB (78%) | Qwen3.6 35B-A3B | UD-Q4_K_M, 20.61 GiB | About 170K | 59.5 tok/s, M5 10-core GPU, MLX 4-bit |
| 36GB | Pro M5 Max (32-core GPU) | 27.00 GiB (75%) | Qwen3.6 35B-A3B | UD-Q4_K_M, 20.61 GiB | Full 262K | 40-52 tok/s, M4 Max 36GB, a Q4_K_M finetune of the same model (#27525) |
| 48GB | Pro M5 Pro, Pro M5 Max (40-core) | 37.44 GiB (78%) | Qwen3.6 35B-A3B | Q8_0, 34.37 GiB | About 100K | 64.7 tok/s, M5 Pro 20-core GPU, MLX 8-bit |
| 64GB | Pro M5 Pro (20-core), Pro M5 Max (40-core) | 51.84 GiB (81%) | Qwen3.8 27B | Q8_0, 27.05 GiB | Full 262K | Not measured; about 19 tok/s on M5 Max (estimate) |
| 128GB | Pro M5 Max (40-core) | 107.52 GiB (84%) | gpt-oss 120B | MXFP4, 59.03 GiB | Full 128K | 79.7 tok/s, M5 Max 40-core, MLX |
How to read the table.
- File sizes are byte counts from the Hugging Face API, read 2026-10-20. Qwen files are Unsloth GGUFs. gpt-oss files are ggml-org GGUFs. GiB = 230 bytes.
- Context that fits = default limit, minus 1 GiB for compute buffers (our assumption), minus the file. We divide the rest by the KV cache per token from each model’s
config.json. The cache is f16. - Speeds are community-reported, at short context (1K-4K). MLX speeds come from oMLX community benchmarks. They are not llama.cpp numbers.
- The limit values come from llama.cpp startup logs in public GitHub issues. Some logs come from a Mac mini or another Mac with the same RAM, not a MacBook. Treat them as close, not exact. Sources are listed below.
Why Qwen3.6 35B-A3B Is the Overall Winner
It is the one model that is both strong and fast on a laptop chip.
- It fits from 32GB up, with about 170K of context at 4 bits. Its cache costs only 20 KiB per token, because only 10 of its 40 layers keep a growing cache (10 layers × 2 KV heads × 256 × 2 × 2 bytes).
- It is a mixture-of-experts model. Each token reads only the active experts, not all 35B parameters. That is why a 153 GB/s base M5 still generates about 60 tok/s.
- It scores well. Qwen’s model card gives it 80.4 on LiveCodeBench v6 (vendor number). Apache-2.0 license.
- It even runs on 24GB, just. Unsloth’s UD-Q3_K_XL file is 15.69 GiB. That leaves 1.07 GiB, about 56K tokens of cache. Expect lower quality at 3 bits.
When to pick something else. Qwen3.8 27B is the stronger coder: 90.3 on LiveCodeBench v6 against 80.4 (vendor numbers). But it is a dense model. It reads all its weights for every token, so it is several times slower on the same Mac.
Pick the Right Quant for Dense Models on a Mac
This is the one tip that changes dense-model speed on a Mac.
In llama.cpp issue #27525, an M4 Max 36GB MacBook Pro decoded Qwen3.8 27B at 6.3-8.8 tok/s with Unsloth’s UD-Q4_K_XL, UD-Q5_K_XL and Q6_K files. MoE models ran at 40-52 tok/s on the same Mac.
A reply in the same thread measured Qwen3.8 27B on an M1 Max (400 GB/s) in llama.cpp:
| Quant | File | Decode, short context |
|---|---|---|
| IQ4_NL | 16.34 GB | 14.29 tok/s |
| Q4_1 | 17.54 GB | 13.53 tok/s |
| Q3_K_M | 13.82 GB | 12.63 tok/s |
Both sets are community-reported. The replier says XL quants are slow on Metal, and a standard quant gets about twice the speed on similar hardware.
The issue also quotes about 35 tok/s for the MLX-based oMLX server on the same Mac. The replier showed that number needs more bandwidth than the M4 Max has. We do not use it.
So for a dense 27B model on a Mac, try IQ4_NL or Q4_1 before an XL file. Keep llama.cpp or Ollama for MoE models like Qwen3.6 35B-A3B and gpt-oss.
How Fast Each MacBook Chip Is
Bandwidth sets the ceiling for generation speed. This table uses one fixed test: Llama 7B at Q4_0 in llama.cpp, from the community table in discussion #4167. Use it to compare chips, not to predict your model’s speed.
| Chip | Bandwidth | GPU cores | Llama 7B Q4_0 generation |
|---|---|---|---|
| M4 | 120 GB/s | 10 | 24.11 tok/s |
| M5 | 153 GB/s | 10 | 31.88 tok/s |
| M4 Pro | 273 GB/s | 16 / 20 | 49.64 / 50.74 tok/s |
| M5 Pro | 307 GB/s | 16 / 20 | 67.59 / 66.33 tok/s |
| M4 Max | 410 GB/s | 32 | 69.95 tok/s |
| M4 Max | 546 GB/s | 40 | 83.06 tok/s |
| M5 Max | 460 GB/s | 32 | No data yet |
| M5 Max | 614 GB/s | 40 | 119.92 tok/s |
Bandwidth for M5 chips is from apple.com, read 2026-10-20. The #4167 table lists the M5 at 154 GB/s; Apple’s spec page says 153 GB/s.
Two facts from this table. The 16-core and 20-core M5 Pro run at the same speed, because both have 307 GB/s. The M5 Pro is close to an M4 Max with 32 GPU cores. An M4 Max owner has no speed reason to move to an M5 Pro.
The 64GB speed estimate. Hardware Corner measured Qwen3.8 27B (Q4_K_S, 16.68 GiB) at 31.4 tok/s on an M5 Max 40-core with 128GB, at 4K context (source, updated 2026-08-17). Generation speed scales roughly with the bytes read per token. So the 27.05 GiB Q8_0 file gives about 31.4 × 16.68 ÷ 27.05 ≈ 19 tok/s on that chip. On a 64GB M5 Pro (half the bandwidth), expect about half that. These are our estimates, not measurements.
How Much RAM the GPU Gets on Each MacBook
macOS reports a “recommended max working set” to Metal. llama.cpp prints it at startup. It divides the byte count by 106 and calls the result “MB” (source line). So 12,713.12 “MB” is 11.84 GiB, not 12.4.
| RAM | Logged value | GiB | Share of RAM | Machine in the log |
|---|---|---|---|---|
| 16GB | 12,713.12 MB | 11.84 | 74.0% | M2 Mac mini (#20704) |
| 24GB | 19,069.67 MB | 17.76 | 74.0% | Apple M4 (audio.cpp #356) |
| 32GB | 26,800.60 MB | 24.96 | 78.0% | M4 Mac mini (harborclerk #684) |
| 36GB | 28,991.03 MB | 27.00 | 75.0% | M3 Pro (#13865) |
| 48GB | 40,200.90 MB | 37.44 | 78.0% | M4 Pro MacBook Pro (#20141) |
| 64GB | 55,662.79 MB | 51.84 | 81.0% | M4 Pro Mac mini (#20011) |
| 128GB | 115,448.73 MB | 107.52 | 84.0% | M5 Max 40-core (#21680) |
The “75% rule” is only right for small Macs. The share grows with RAM. A 128GB Mac gives the GPU 84%, not 75%. Pages that apply 75% to 128GB undercount it by about 11 GiB.
One mistake to avoid. The harborclerk issue reads the same 26,800.60 “MB” as 81.8% of a 32GB Mac. That treats it as MiB. The correct share is 78.0%. Use the GiB column above.
How to Raise the Limit (and the Risk)
You can give the GPU more memory with one command:
sudo sysctl iogpu.wired_limit_mb=N
- N is in MiB. llama.cpp’s gpt-oss guide raises a 192GB Mac to 180 GiB with
iogpu.wired_limit_mb=184320(180 × 1024) (discussion #15396). - The rule from the mlx-lm README: N must be larger than the model size and smaller than the machine’s memory.
- The risk: memory wired for the GPU is not available to macOS and your apps. Set N too close to your RAM and the system runs short. Your browser and editor compete with the model.
- Our rule (an assumption, not a vendor number): leave at least 8 GiB for macOS on a machine you also work on. On a 48GB Mac, 40960 (40 GiB) gives the model 2.56 GiB more than the default.
- Check the value with
sysctl iogpu.wired_limit_mbafter a reboot. We did not verify whether the setting survives a restart.
Where raising the limit does not help. On 64GB, gpt-oss 120B needs about 60 GiB for weights and buffers before any context. That leaves macOS under 4 GiB. We do not recommend it. Buy 128GB for that model, or run Qwen3.8 27B Q8_0 instead.
Which MacBook to Buy for Local LLMs
Apple sells no M4 MacBooks now. Prices below are from apple.com, read 2026-10-20, as of October 2026. We did not read prices for 64GB and 128GB configs; use Apple’s configurator.
| MacBook (as of October 2026) | RAM | Bandwidth | Price | Best local model |
|---|---|---|---|---|
| MacBook Air 13” M5 (10-core GPU) | 24GB / 512GB | 153 GB/s | $1,499 | gpt-oss 20B |
| MacBook Pro 14” M5 | 24GB / 1TB | 153 GB/s | $2,199 | gpt-oss 20B |
| MacBook Pro 14” M5 | 32GB / 1TB | 153 GB/s | $2,399 | Qwen3.6 35B-A3B (4-bit) |
| MacBook Pro 14” M5 Pro (20-core GPU) | 24GB / 1TB | 307 GB/s | $2,699 | gpt-oss 20B |
| MacBook Pro 14” M5 Pro (20-core GPU) | 48GB / 1TB | 307 GB/s | $3,299 | Qwen3.6 35B-A3B (8-bit) |
| MacBook Pro 16” M5 Pro (20-core GPU) | 48GB / 1TB | 307 GB/s | $3,599 | Qwen3.6 35B-A3B (8-bit) |
| MacBook Pro 14” M5 Max (32-core GPU) | 36GB / 2TB | 460 GB/s | $4,099 | Qwen3.6 35B-A3B (4-bit) |
| MacBook Pro 14” M5 Max (40-core GPU) | 48GB / 2TB | 614 GB/s | $4,699 | Qwen3.6 35B-A3B (8-bit) |
| MacBook Pro 16” M5 Max (40-core GPU) | 48GB / 2TB | 614 GB/s | $4,999 | Qwen3.6 35B-A3B (8-bit) |
Our picks.
- Cheapest MacBook that runs the winner: the 14” M5 with 32GB at $2,399. It runs Qwen3.6 35B-A3B at 4 bits with about 170K of context.
- Best value: a 48GB M5 Pro. It runs the 8-bit file, and 307 GB/s is twice the base M5. The 14” is $3,299; the 16” is $3,599. A 48GB+ Mac is the tier we point most readers to.
- Skip the 36GB M5 Max. It costs $4,099 and holds less than a 48GB M5 Pro. It costs $800 more than the 14” 48GB M5 Pro, and it cannot load the 8-bit file.
- Buy 128GB only if you need gpt-oss 120B or two big models loaded at once. It requires the 40-core M5 Max. See Best Models for a MacBook Pro 128GB.
- On a budget: a 24GB MacBook Pro runs gpt-oss 20B with its full 128K window. Check the chip and RAM on any listing before you buy.
FAQ
What is the best local LLM for a MacBook? Qwen3.6 35B-A3B on 32GB or more. On 16GB run Qwen3.5 9B. On 24GB run gpt-oss 20B. On 128GB run gpt-oss 120B.
What is the best local LLM for a MacBook Air M4? It depends on the RAM. On 16GB, Qwen3.5 9B at Q8_0 (8.87 GiB). On 24GB, gpt-oss 20B (11.28 GiB, full 128K window). On 32GB, Qwen3.6 35B-A3B at 4 bits. The M4 has 120 GB/s, so expect about three quarters of the base M5’s speed (24.11 vs 31.88 tok/s in #4167).
What is the best LLM for an M4 Max MacBook Pro? Use your RAM row. On 36GB, run Qwen3.6 35B-A3B at 4 bits with its full 262K window. On 128GB, run gpt-oss 120B. Details are on our M4 Max page.
Can a 64GB MacBook Pro run gpt-oss 120B? Not by default. The file is 59.03 GiB and the limit is 51.84 GiB. Raising the limit far enough leaves macOS under 4 GiB.
How do I raise the GPU memory limit on a Mac?
sudo sysctl iogpu.wired_limit_mb=N, with N in MiB. Leave several GiB for macOS.
Sources
- Apple: MacBook Pro specs, MacBook Air specs, Buy MacBook Pro, Buy MacBook Air, read 2026-10-20.
- Hugging Face API file trees: unsloth/Qwen3.6-35B-A3B-GGUF, unsloth/Qwen3.8-27B-GGUF, unsloth/Qwen3.5-9B-GGUF, ggml-org/gpt-oss-20b-GGUF, ggml-org/gpt-oss-120b-GGUF, read 2026-10-20.
config.jsonfor Qwen/Qwen3.6-35B-A3B, Qwen/Qwen3.8-27B, Qwen/Qwen3.5-9B, openai/gpt-oss-20b, openai/gpt-oss-120b, read 2026-10-20.- llama.cpp: discussion #4167 (chip speeds), discussion #15396 (gpt-oss guide), issue #27525 (dense models on Metal), and the working-set issues in the table above.
- oMLX community benchmarks: Qwen3.6-35B-A3B on M5 32GB, M5 Pro 20-core 48GB 4-bit, M5 Pro 48GB 8-bit; gpt-oss-120b on M5 Max 128GB.
- Hardware Corner Qwen3.8 27B tests, updated 2026-08-17.
See Also
Need OpenClaw fixed live?
Remote rescue sessions for gateway, auth, tunnel, VPS, and model access problems.
See Rescue Session