Qwen Code is an open-source terminal agent under the Apache 2.0 license. It connects to Qwen models through QwenCloud, Alibaba Cloud Model Studio or any provider with a compatible API. You can install it with the official script, through npm or through Homebrew, and pay one of four ways: Token Plan, Coding Plan, pay-as-you-go or an API key entered by hand. Below: the install commands, the story of the Lite plan and a plain comparison with Claude Code.
What Qwen Code is
Qwen Code runs in the terminal. It writes, completes and edits code from a request in plain language. The GitHub repository calls it an agentic framework with auto-memory, auto-skills and several API protocols at once: OpenAI, Anthropic, Gemini and Qwen. There are plugins for VS Code, JetBrains and Zed, plus a desktop app and a web interface. Among the built-in commands, the ones to know are /review, /batch, /loop and /bugfix.
Apache 2.0 means you can read, fork and modify the code. That covers the CLI shell, not the Qwen models themselves: access to those is billed separately.
Installing Qwen Code
On macOS and Linux, the README of QwenLM/qwen-code gives this command:
curl -fsSL https://qwen-code-assets.oss-cn-hangzhou.aliyuncs.com/installation/install-qwen-standalone.sh | bash
On Windows, the same thing runs in PowerShell:
irm https://qwen-code-assets.oss-cn-hangzhou.aliyuncs.com/installation/install-qwen-standalone.ps1 | iex
When the installation finishes, restart the terminal so the environment variables are picked up, then check the version:
qwen --version
If you already have Node.js 22 or newer, you can install the package with npm straight from the official repository. On macOS and Linux there is also Homebrew: brew install qwen-code.
npm install -g @qwen-code/qwen-code@latest
The VS Code plugin needs editor version 1.85.0 or newer, and JetBrains has to support the Agent Client Protocol.
Authorization and pricing plans
Run qwen and type /auth to set up access in the interface. You can also just put the key into settings.json by hand. There are four ways to pay: Token Plan for personal use, Token Plan for a team, Coding Plan with a fixed monthly quota, or ordinary pay-as-you-go billing for the tokens you use.
With Coding Plan, the dates matter. The Lite plan has been closed to new subscriptions since March 20, 2026, and for people who signed up earlier, renewals and upgrades were switched off on April 13, 2026. The current Pro plan costs 50 dollars a month and includes up to 90 thousand requests a month, with limits on a 5-hour window and on a week. The subscription is not tied to one tool: over a compatible protocol the same Coding Plan works with Claude Code, Cline, Cursor and several other programs.
Qwen Code vs Claude Code
Both do the same job. An agent in the terminal reads the codebase, edits files and runs commands on your instruction. They differ in economics and maturity.
As a shell, Qwen Code is free and its code is open. You pay only for the model you plug in, including third-party ones, as long as they speak a compatible protocol. There is plenty of freedom, but you assemble the model setup for your task yourself.
Claude Code is Anthropic's paid tool, but its agent side has been tested for longer. On long multi-step tasks it loses the thread less often, and on large codebases it handles tools more reliably. That is what the premium buys. The article on Claude Code alternatives compares models and agents in detail.
Connecting Claude Code through codexkey
Say paying for Qwen Code from Russia has already caused trouble: verifying an Alibaba Cloud account, or a foreign card. And what you need is Claude. Then Claude Code is set up through codexkey, with no Anthropic account and no VPN.
export ANTHROPIC_BASE_URL="https://api.codexkey.online"
export ANTHROPIC_AUTH_TOKEN="sk_cdx_your_key"
export ANTHROPIC_DEFAULT_OPUS_MODEL="claude-opus-5-5[1m]"
export ANTHROPIC_DEFAULT_SONNET_MODEL="claude-sonnet-5[1m]"
export ANTHROPIC_DEFAULT_HAIKU_MODEL="claude-sonnet-5"
claude
The ANTHROPIC_DEFAULT_* lines are required. Without them Claude Code asks for its own default models and answers "There's an issue with the selected model".
The key is issued in your account, in the "API keys" section. Payment goes through SBP (the Russian Faster Payments System) or a Russian card, and a top-up starts at 1 dollar. In the catalog on October 29, 2026, Claude Sonnet 5 costs $0.52 per million input tokens and $2.6 for output, Claude Opus 5.5 $0.86 and $4.32. Qwen3.8 models are there too (qwen3.8-max, qwen3.8-flash), and you can pick them in Claude Code with the /model command. The full instructions for all three systems are in the Claude Code guide.
If you care about the models themselves rather than the tools around them, read the comparison Claude vs Qwen and the piece on the Qwen 3.8 lineup.
FAQ
Is Qwen Code free?
The tool itself is free: the code is open under Apache 2.0. You pay for the model it connects to, through Token Plan, Coding Plan or pay-as-you-go billing for tokens on Alibaba Cloud.
How do I install Qwen Code on Windows?
The official way from the README is to run irm https://qwen-code-assets.oss-cn-hangzhou.aliyuncs.com/installation/install-qwen-standalone.ps1 | iex in PowerShell and restart the terminal. npm works too if Node.js 22+ is installed. After installing, qwen --version checks the version.
What happened to the Coding Plan Lite plan?
It was closed to new subscribers on March 20, 2026, and on April 13, 2026 renewals and upgrades were switched off for those who had signed up earlier. The basic current plan is now Pro.
How is Qwen Code different from Claude Code?
As a shell, Qwen Code is free, its code is open, and it connects flexibly to different models over a compatible protocol. Claude Code is paid, but its agent side is more reliable on long, hard tasks: it loses less context and follows instructions more precisely when there are many files.
Can Qwen Code be connected to Claude models?
The developers state support for several protocols, Anthropic among them, so with a suitable key the connection is technically possible. But for full agentic coding with Claude people usually take Claude Code: its integration with Anthropic's tools and hooks goes deeper.
Does installing Qwen Code work from Russia?
There have been no reports of the install scripts being blocked. The main obstacle for users in Russia is usually paying for models through Alibaba Cloud, not installing the CLI itself.