Qwen3.8-27B as a Local Cursor and Cline Backend in 2026: Apache 2.0, One 24GB Card, and Coding Scores That Crowd Sonnet 5
TL;DR: Alibaba shipped Qwen3.8-27B open weights on August 14, 2026 — Apache 2.0, 27.78B dense parameters, native vision, 262K context, and a Qwen-reported 61.7 on SWE-bench Pro that lands within 1.5 points of Claude Sonnet 5. The 18GB Ollama build runs on a single 24GB card. It is the strongest local coding backend a consumer GPU has ever had.
| Qwen3.8-27B (local) | Qwen3.8-27B (OpenRouter API) | Claude Sonnet 5 (API) | |
|---|---|---|---|
| Best for | Daily Cline/Cursor coding on a 24GB GPU, $0 marginal | Same model without the hardware | Hardest multi-file agentic work |
| SWE-bench Pro | 61.7 (Qwen-reported) | 61.7 | 63.2 |
| Price | Free weights (Apache 2.0) + electricity | $0.45/$3.20 per M tokens (listed at launch) | $2/$10 per M intro until Aug 31, then $3/$15 |
| The catch | Dense 27B = slower than MoE peers; KV cache squeezes 24GB at long context | Output rate is 10× DeepSeek V4-Flash | Cloud-only; per-token bill compounds in agent loops |
Honest take: If you own a 24GB GPU, pull this today and make it your default local backend — it retires Ornith-1.0 35B as our standing pick for the slot. Keep Sonnet 5 on speed dial for the hardest 20% of tasks; the benchmark gap is small but real.
Seven runs in a row we checked for these weights, and Alibaba finally delivered: Qwen3.8-27B landed on Hugging Face at 15:00 UTC on August 14, 2026, alongside the open weights for its 2.4-trillion-parameter sibling Qwen3.8-Max. The Max is multi-node territory nobody reading this will self-host. The 27B is the release that matters for this site: a dense, Apache 2.0, vision-capable model that Qwen says outperforms its own Qwen3.7-Plus hosted flagship overall — and it fits on the same used RTX 3090 that has anchored every local-backend guide we’ve published this year.
Everything below was verified August 16, 2026 against the official Qwen announcement, the Hugging Face model card, the Ollama library listing, and the OpenRouter listing — with the recurring caveat that several pages were cross-verified through search summaries because direct fetches are egress-blocked in this environment. Benchmark numbers are Qwen-reported unless noted; no independent SWE-bench run existed as of this writing, two days after release.
What actually shipped on August 14
The exact checkpoint is 27.78B parameters, dense (every parameter active per token — no MoE routing), with a native vision encoder that accepts images and video alongside text. Context is 262,144 tokens native, extendable to 1M with YaRN. Maximum output is 131,072 tokens. Thinking is flexible: the model runs with reasoning on or off per request, and the difference matters for agent loops (more on that below).
The license is plain Apache 2.0 — the question we flagged as the make-or-break check when this topic entered our queue on August 5. No user-count clause, no regional carve-outs, no “Qwen License” attribution requirements. Commercial use, fine-tuning, and redistribution are all clean. That puts it in the same legally-safe bucket as Codestral 2 and the other backends we recommend for team use, and a tier above Meta’s Llama Community License.
Distribution on day two was already complete:
| Channel | What you get |
|---|---|
Hugging Face Qwen/Qwen3.8-27B | Official BF16 weights, Apache 2.0 |
Hugging Face Qwen/Qwen3.8-27B-FP8 | Official FP8 for vLLM/SGLang serving |
Ollama qwen3.8:27b | Default Q4_K_M build: 18GB total (17GB weights + 931MB vision encoder); requires Ollama v0.32.12+ |
Ollama qwen3.8:27b-mlx | Same footprint, compiled for Apple Silicon Metal |
| unsloth / bartowski / lmstudio-community GGUFs | Community quants for llama.cpp and LM Studio; Q4_K_M ranges 16.8–19.0GB depending on the pack |
OpenRouter qwen/qwen3.8-27b | Hosted API, $0.45/M input, $3.20/M output listed at launch |
There is also a day-one vLLM recipe on the official vLLM recipes site, so the FP8 self-serving path for teams is documented rather than improvised.
The benchmark jump, and what to trust
Qwen’s reported numbers against its own Qwen3.6-27B — the model this replaces in the same VRAM budget — are not incremental:
| Benchmark | Qwen3.6-27B | Qwen3.8-27B | Claude Sonnet 5 | GLM 5.2 (API) |
|---|---|---|---|---|
| SWE-bench Pro | — | 61.7 | 63.2 | 62.1 |
| Terminal-Bench 2.1 | 63.4 | 73.0 | 80.4 | 81.0 |
| DeepSWE 1.1 | 13.3 | 42.2 | not yet scored | — |
| OSWorld-Verified | 63.9 | 84.3 | 81.2 | — |
(Sonnet 5 and GLM 5.2 columns are the numbers we verified for their own reviews; DeepSWE 1.1 is the independent Datacurve harness, though Qwen’s 42.2 is self-run on it.)
Read the table with the usual discount: every Qwen3.8 number is vendor-reported two days after launch, and vendors run their own harnesses in the most favorable configuration. But even with a several-point haircut, the shape is remarkable. SWE-bench Pro at 61.7 from a 27B dense model puts it within 1.5 points of Sonnet 5 and half a point of GLM 5.2 — a 743B-parameter model you can only realistically use via API. The Terminal-Bench 2.1 jump from 63.4 to 73.0 clears Ornith-1.0 35B’s vendor-reported 64.2, which has been the best local score in the 24GB class since June. And the DeepSWE leap from 13.3 to 42.2 suggests the agentic-loop training is real, not benchmark tuning on one suite.
Where it still loses: Terminal-Bench’s 7-to-8-point gap against Sonnet 5 and GLM 5.2 is the honest measure of how much autonomous multi-step terminal work you give up by going local. For install-test-fix loops that run 40+ steps, the cloud models still fail less.
Hardware reality: it fits, until the context grows
The weights fit a 24GB card with room to spare — the squeeze is the KV cache. A dense 27B at Q4_K_M is roughly 17–19GB before a single token of context. With f16 KV cache at a 64K window, total memory lands around 24–27GB, which is past what an RTX 3090 or 4090 can hold. Ollama’s response to that overflow is not an error: it silently offloads layers to CPU and your throughput craters, which is exactly the failure mode we documented in Ollama not using your GPU.
On a 24GB card, three settings keep it on-GPU:
# 1. Update first — Qwen3.8 support landed in v0.32.12
ollama --version
# 2. Pull the default Q4_K_M build (18GB)
ollama pull qwen3.8:27b
# 3. Cap context explicitly and quantize the KV cache
OLLAMA_FLASH_ATTENTION=1 OLLAMA_KV_CACHE_TYPE=q8_0 OLLAMA_CONTEXT_LENGTH=32768 ollama serve
Expected check after a first prompt: ollama ps should show 100% GPU. If you see a CPU split, drop the context to 24576 or step down to a smaller quant.
Two more sizing notes. First, the Ollama build always loads the 931MB vision encoder; text-only community GGUFs skip it, and that gigabyte is real headroom at this margin. Second, 32K is below the 64K floor Ollama’s own docs recommend for coding agents — the context-length trap we’ve covered before applies with extra force here, because the model’s 262K native window tempts you to configure far more than the card can hold. A 24GB card runs this model well at 24–32K context. If you want 64K+, you want 32GB+ of VRAM or the API.
On speed, be realistic about the architecture: dense means all 27.78B parameters move for every token. Bandwidth arithmetic puts the ceiling on a 936GB/s RTX 3090 at roughly 55 tok/s for a 17GB quant, and real-world numbers land below ceilings; early blog reports claiming 72 tok/s should be treated skeptically until independent benchmarks land. Expect noticeably slower generation than MoE neighbors like Nemotron 3.5 Lightning (~3B active) — the trade is that you get flagship-adjacent quality per token instead of executor-tier quality.
Wiring it into Cline, Cursor, and Claude Code
Cline is the cleanest path. Provider: Ollama. Base URL: http://127.0.0.1:11434 — the bare root, no /v1 suffix; Cline appends its own paths. Model: qwen3.8:27b. Then set Cline’s context-window field to match whatever you configured server-side, or Cline will assume more than the card holds. Ollama tags the model with tools capability, and it’s a dense model rather than a sparse MoE — the class of model that historically fails tool-calling less than the qwen3-coder MoE flakes we documented. Still: two days post-release there is no community consensus on its tool-call reliability in long Cline sessions. Run a 20-step task you can verify before trusting it with a refactor.
Cursor takes the model through the OpenAI-compatible override: Settings → Models → override the OpenAI base URL to http://localhost:11434/v1, enter any non-empty API key, and add qwen3.8:27b as a custom model. The two standing caveats from our Cursor + Ollama guide both apply: the base-URL override is global (your cloud OpenAI models stop working while it’s set), and Tab completion stays on Cursor’s cloud model no matter what — only Chat and Agent route locally.
Claude Code is now a one-liner. Ollama’s launch announcement for this model leads with it:
ollama launch claude --model qwen3.8
That’s the integration we walked through in Claude Code + Ollama, with the config file generated for you. The same launch flow covers OpenCode.
One thinking-mode note for all three tools: Qwen3.8’s reasoning toggle defaults on, and agent harnesses that already plan-then-execute can burn a lot of tokens on redundant thinking. Ollama exposes the switch — --think=false on the CLI, "think": false in the API — and for grunt-work sessions turning it off is usually the right call. Leave it on for architecture questions.
The cost math
Take our standard yardstick session — 50K input, 8K output tokens, a mid-sized Cursor agent run:
- Qwen3.8-27B local: $0 marginal. A 350W GPU at full tilt for the duration costs low single-digit cents of electricity.
- Qwen3.8-27B via OpenRouter: ~$0.048 at the launch-listed $0.45/$3.20 per M. Note that $3.20 output is steep for the size class — more than 10× DeepSeek V4-Flash’s $0.28 — so the API route makes sense for trying the model, less for living on it.
- Claude Sonnet 5: ~$0.18 at intro pricing ($2/$10, ends August 31), ~$0.27 at the standard $3/$15 that starts September 1 — before Sonnet 5’s ~30% heavier tokenizer inflates the real number.
At 20 sessions a day, Sonnet 5 standard pricing runs roughly $160/month; the local model runs $0 plus power. A used RTX 3090 — still hovering around $1,000–$1,500 through 2026 — pays for itself inside a year for a heavy solo user, and that’s the conservative case since the same card also serves every other local model we cover. If you’d rather rent the VRAM first, RunPod will put you on a 24GB card by the hour to test the fit before buying. For the full price landscape, see the AI code editor cost comparison; for which GPU tier buys which model class, the sister-site guide to local AI models by VRAM is the deeper hardware treatment, and aifoss.dev tracks the FOSS serving stack side.
Where it breaks
The failure modes, ranked by how likely they are to bite:
- Silent CPU offload at long context. The #1 issue by construction: 18GB model + unquantized KV + optimistic context = layers on CPU and 5 tok/s. Fix above; symptoms and diagnosis in the GPU-fallback guide.
- Old Ollama. Anything below v0.32.12 doesn’t know the architecture. If
ollama pullsucceeds but generation errors, update the daemon before debugging anything else — and if the tools can’t reach it at all, that’s the connection-refused checklist. - Unproven tool calling. No 40-step-session track record yet. Dense architecture is a good prior, not a guarantee. Test before trusting.
- Dense-model patience tax. If your workflow is high-volume boilerplate where speed beats smarts, a fast MoE executor plus this model as the planner is the better split than running everything through 27.78B dense parameters.
- Vendor-only benchmarks. Every number above is Qwen’s own. Independent SWE-bench Pro and Terminal-Bench runs typically land within two to three weeks of a release this prominent; we’ll update this article if they diverge meaningfully.
Verdict
Qwen3.8-27B is the new default local coding backend for a 24GB card — full stop. It posts (vendor-reported) agentic-coding numbers no locally-runnable model in this VRAM class has approached, under a license you can build a business on, with day-one distribution across Ollama, llama.cpp, MLX, and vLLM. Ornith-1.0 35B held this slot for seven weeks on the strength of a 75.6 SWE-bench Verified; Qwen3.8-27B matches the class on quality claims and beats it on context depth, vision input, license clarity, and ecosystem speed. JetBrains Mellum 2 remains the pick only if your ceiling is a 12GB card.
The cloud still earns its keep at the margins: Sonnet 5 for the longest, hardest agent loops, and cheap APIs like DeepSeek V4-Flash when you need volume without owning hardware. But the gap between “local toy” and “local daily driver” closed another notch this week, and this is the release that closed it.
FAQ
Does Qwen3.8-27B run on a 16GB GPU? Not at Q4_K_M — 17–19GB of weights alone. Aggressive sub-4-bit quants may technically load, but in our experience across this model class the quality loss below Q4 defeats the purpose for coding. On 16GB, run Mellum 2 or a ~15GB-class model instead.
Is the license really unrestricted? Apache 2.0, confirmed across the official Hugging Face repo and independent coverage. No MAU thresholds, no attribution mandates beyond the license text, commercial use and fine-tuning permitted.
Should I use thinking mode in Cline? Off for routine implement-and-fix loops (faster, cheaper on your own compute time), on for planning and debugging sessions where the reasoning trace earns its tokens.
What about Qwen3.8-Max? The 2.4T flagship’s weights are also open now, but that’s multi-node serving hardware — for anyone reading this, Max is an API decision, not a local one. The 27B is the release built for your hardware.
Sources
- Qwen open-weights announcement — @Alibaba_Qwen on X
- Qwen/Qwen3.8-27B — Official Hugging Face model card
- Qwen/Qwen3.8-27B-FP8 — Official FP8 variant
- qwen3.8:27b — Official Ollama library listing
- Ollama launch announcement for Qwen 3.8 27B — @ollama on X
- Alibaba’s Qwen team releases Qwen 3.8 models under Apache 2.0 — The Decoder
- Qwen3.8 27B — OpenRouter pricing and providers
- Qwen/Qwen3.8-27B — vLLM official recipes
- unsloth/Qwen3.8-27B-GGUF — Community GGUF quants
- Qwen 3.8 benchmarks: what’s actually verified so far — Yotta Labs
- Qwen 3.8 27B — Hacker News discussion
Last updated August 16, 2026. Pricing and features change frequently; verify current state before purchasing.
Was this article helpful?
Thanks for the feedback — it helps improve future articles.