Starting & Approval Modes

Action Shortcut
Install (npm, Node 20+) npm install -g @qwen-code/qwen-code@latestnpm install -g @qwen-code/qwen-code@latestnpm install -g @qwen-code/qwen-code@latest
Start Qwen Code in the current project qwenqwenqwen
Submit your prompt EnterEnterEnter
Cycle approval modes (plan → default → auto-edit → auto → yolo) ShiftTabTabShiftTab
Switch to (or exit) plan mode /plan/plan/plan
Change the approval mode /approval-mode/approval-mode/approval-mode
Cancel the request / clear input (twice to exit) CtrlCCtrlCCtrlC
Exit when input is empty (twice to confirm) CtrlDCtrlDCtrlD

Input & Editing

Action Shortcut
Insert a new line ShiftEnterShiftEnterShiftEnter
Insert a new line (alternate) CtrlJCtrlJCtrlJ
Autocomplete the current suggestion TabTabTab
Reverse-search history CtrlRCtrlRCtrlR
Retry the last failed request CtrlYCtrlYCtrlY
Paste (saves and references a clipboard image) CmdVAltVCtrlV
Open the input in an external editor CtrlXCtrlXCtrlX
Toggle shell mode (when input is empty) !!!
Toggle the keyboard-shortcuts list (empty input) ???
Move to start of line CtrlACtrlACtrlA
Move to end of line CtrlECtrlECtrlE
Delete to end of line CtrlKCtrlKCtrlK
Delete to start of line CtrlUCtrlUCtrlU
Delete the previous word CtrlWCtrlWCtrlW
Previous entry in history UpUpUp
Next entry in history DownDownDown

Display & Session

Action Shortcut
Clear the screen CtrlLCtrlLCtrlL
Toggle compact mode (hide tool output / thinking) CtrlOCtrlOCtrlO
Toggle tool descriptions CtrlTCtrlTCtrlT
Toggle Markdown between rich and raw source OptionMAltMAltM
Print a long response in full (disable truncation) CtrlSCtrlSCtrlS
Promote a foreground shell command to a background task CtrlBCtrlBCtrlB
Scroll history up one line ShiftUpShiftUpShiftUp
Scroll history down one line ShiftDownShiftDownShiftDown
See the context the IDE sent CtrlGCtrlGCtrlG

Slash Commands — Session

Action Shortcut
Show help /help/help/help
Generate a QWEN.md project context file /init/init/init
Compress history to save tokens /compress/compress/compress
Resume a previous session /resume/resume/resume
Generate a one-line session recap /recap/recap/recap
Restore files to their pre-tool state /restore/restore/restore
Show session statistics /stats/stats/stats
Switch the active model /model/model/model
Exit Qwen Code /quit/quit/quit

Slash Commands — Qwen Extras

Action Shortcut
Agent Arena — pit models against each other /arena/arena/arena
Set UI / output language /language/language/language
Ask a quick side question without derailing /btw/btw/btw
List and run skills /skills/skills/skills
Open the Memory Manager /memory/memory/memory
Save a durable memory /remember/remember/remember
Review code changes with parallel agents /review/review/review
Run a prompt on a recurring schedule /loop/loop/loop
Toggle Vim editing mode /vim/vim/vim

File & Shell References

Action Shortcut
Reference a file's contents @path/to/file@path/to/file@path/to/file
Reference a directory (recursive) @path/to/dir@path/to/dir@path/to/dir
Run a single shell command !command!command!command
No shortcuts found. Try a different search term.

Frequently Asked Questions

Is Qwen Code the same as Gemini CLI?
No, but they're closely related. Qwen Code is Alibaba's open-source terminal coding agent, forked from Google's Gemini CLI — so a lot of the keyboard shortcuts and the @-mention / slash-command structure are shared. Qwen Code adds its own touches, most notably a five-step Shift+Tab approval cycle and commands like /arena, /language, /btw, and /recap. You run it with the qwen command.
How do I switch modes in Qwen Code?
Press Shift+Tab (or just Tab on Windows) to cycle through the approval modes: plan, default, auto-edit, auto, and yolo. That's five modes — more than most CLI agents. You can also use /plan to jump to plan mode or /approval-mode to set it directly.
How do I add a new line in Qwen Code without sending?
Press Shift+Enter to insert a new line. Ctrl+J, Ctrl+Enter, and Cmd+Enter also work, which is handy because some terminals can't pass Shift+Enter through cleanly.
How do I exit Qwen Code?
Press Ctrl+C twice (the first press cancels the current request and clears the input; the second exits), or press Ctrl+D twice when the input is empty. You can also type /quit to exit immediately.
What is the /arena command in Qwen Code?
Agent Arena (/arena) runs several models on the same task in parallel — each as an independent agent in its own isolated Git worktree — then lets you compare the results and merge the winner. For example: /arena --models qwen3.5-plus,glm-5,kimi-k2.5 "Refactor auth to use JWT". It's one of Qwen Code's most distinctive features.
Can I change Qwen Code's interface language?
Yes. Use /language ui <code> to set the interface language (for example /language ui zh-CN for Chinese or /language ui en-US for English), and /language output <code> to set the language the model replies in. This i18n support is a Qwen-distinct addition over Gemini CLI.