/terminal-setup error message contradicts itself regarding Windows Terminal support
Preflight Checklist
- [x] I have searched existing issues and this hasn't been reported yet
- [x] This is a single bug report (please file separate reports for different bugs)
- [x] I am using the latest version of Claude Code
What's Wrong?
The /terminal-setup command displays contradictory information about Windows Terminal support.
The error message states: "Terminal setup cannot be run from windows-terminal"
But then immediately instructs: "Run /terminal-setup directly in one of these terminals: Windows: Windows Terminal"
This creates confusion about whether Windows Terminal is actually supported for this feature.
What Should Happen?
The error message should be consistent and provide clear, accurate guidance:
Either:
- Remove "Windows Terminal" from the supported terminals list if it's not actually supported, OR
- Fix the detection logic to properly support Windows Terminal
The error message should not contradict itself by both rejecting and recommending the same terminal.
Error Messages/Logs
Steps to Reproduce
- Open Windows Terminal
- Run the
/terminal-setupcommand in Claude Code - Observe the contradictory error message
Expected vs Actual:
- The error says Windows Terminal is NOT supported: "cannot be run from windows-terminal"
- But then lists Windows Terminal as supported: "Windows: Windows Terminal"
Environment:
- Platform: Windows
- Terminal: Windows Terminal
- This appears to be an error message consistency issue rather than a functional bug
Claude Model
None
Is this a regression?
No, this never worked
Last Working Version
_No response_
Claude Code Version
Latest (this is an error message consistency issue, not version-specific)
Platform
Anthropic API
Operating System
Windows
Terminal/Shell
Windows Terminal
Additional Information
_No response_
35 Comments
I used CC to submit this with Playwright ;)
Does anyone know if there is a workaround so we can get shift+enter working in windows terminal?
Update: @IKnewOne provided this workaround downthread: https://github.com/anthropics/claude-code/issues/8208#issuecomment-3578237605
If it helps at all I see this issue in Claude Code 2.0.24 running the most recent versions of both Windows Terminal (1.23.12811.0) and Windows Terminal Preview (1.24.2682.0)
I tried also with an older version
Microsoft.WindowsTerminal_1.23.12371.0. Same problemHaving this issue with the following environment:
While this seems like a simple QoL issue, my
Shift+Entermuscle memory is ruining chat sessions, or simple mistypes when trying to utilize the\workaround. Having a fix for this would be a very welcome improvement!After spending a week off using claude, I now have the opposite problem, I keep hitting \ + enter, and accidentally sending my co-workers half-finished thoughts on slack!
I'm experiencing this same issue:
PowerShell 7.5.4 + Windows Terminal app + Windows 11 also happen
Same here!
same here with
WT 1.23.12811.0
CC 2.0.50 (Claude Code)
ask claude for the json command & edit your settings.json file in the windows terminal (ctrl + shift + ,)
This update to Windows Terminal settings.json is working for me:
The solution from @jrnewton didn't work for me right away; it seems like this is the result of terminal later altering his command. What worked for me was
After saving json and restarting the terminal, the values changed to the id version ( "id": "User.sendInput.DFCDAF06" ), but it kept working
The json setting was generated by Claude Code... and pasted into settings.json by me. I don't think it was modified after the fact...
This worked for me, previous responses didn't
hey guys. I had this problem also, chatted with ChatGPT 5.1, and the devil solved it :)
I use vscode with WSL (so the vscode client is on windows 11, and it connects to vscode server on WSL). The bug is from vscode actually. Here's the part of the chat that solved it:
====chatgpt response====
Yeah, this one’s not on you. It’s a VS Code + WSL mess.
Right now:
showkey -ashows only^M 13 0x0dfor Shift+Enter → VS Code is not sending the ESC (\^[) that yourkeybindings.jsonclaims.keybindings.jsonat/home/hisham/.config/Code/User/keybindings.jsonhas the Claude binding.That means one thing:
Claude’s
/terminal-setupscript is dumb here: it writes to~/.config/Code/User/keybindings.jsoninside WSL, but VS Code (running on Windows) readsC:\Users\Hisham\AppData\Roaming\Code\User\keybindings.json. So the binding never actually applies.---
Fix: put the binding in the real VS Code keybindings file
``
text
``Ctrl + Shift + P
“Open Keyboard Shortcuts (JSON)”
and hit Enter.
This opens the actual keybindings file VS Code uses on Windows, something like:
``
``C:\Users\Hisham\AppData\Roaming\Code\User\keybindings.json
``
json
``[
{
"key": "shift+enter",
"command": "workbench.action.terminal.sendSequence",
"args": {
"text": "\^[\r"
},
"when": "terminalFocus"
}
]
If there are already other bindings, just add this object inside the array, separated by commas.
Ctrl+K Ctrl+S), search forshift+enterand you should see:workbench.action.terminal.sendSequenceterminalFocusIf you don’t see it there, you’re still editing the wrong file.
---
Verify the binding actually works
In the WSL terminal in VS Code (no Claude running), run:
Press Shift+Enter.
You should now see:
If you see both 27 and 13 → VS Code is sending ESC + Enter correctly.
Before, you only had the 13 line.
---
Use it with Claude
Now:
At the
You:prompt:If Shift+Enter is still just “send”, that’s on Claude Code’s current behavior, not VS Code. But your keybinding and terminal wiring will finally be correct.
---
Devil’s advocate: this whole thing is brittle. Claude’s
/terminal-setupdoesn’t understand WSL and writes to the wrong config path. If Anthropic doesn’t fix that, you’ll have to remember that any “automatic” keybinding changes it does inside WSL are basically no-ops and you need to mirror them manually into the Windows-sidekeybindings.json.Workaround for Windows Terminal users:
Add this to your Windows Terminal settings.json:
"actions": [
{
"command": {
"action": "sendInput",
"input": "\^[\r"
},
"keys": "shift+enter"
}
]
Steps:
Shift+Enter now works for multi-line prompts in Claude Code.
This issue has been inactive for 30 days. If the issue is still occurring, please comment to let us know. Otherwise, this issue will be automatically closed in 30 days for housekeeping purposes.
it's still relevant
Seems this is still a bug.
This setup works for me on Windows 11, Windows terminal 1.23.13503.0 running PowerShell 7.5.4.
Open Visual Studio Code settings.json:
actionsarray add this as the last entry:keybindingsarray add this as the last entry:@chrisboulet Your fix worked, thank you!
Still an issue on
CC v2.1.31
Windows Terminal
Win11
Still an issue on:
Can confirm the
\nworkaround from @KnewOne works. Adding this to Windows Terminalsettings.json:After saving, Windows Terminal auto-converts it to the
idformat (User.sendInput.DFCDAF06), but Shift+Enter continues to work correctly in Claude Code.The
/terminal-setupcommand still rejects Windows Terminal despite listing it as a supported terminal. The contradictory error message remains unchanged.Still an issue on Windows 11 Pro using Windows Terminal ("windows-terminal" according to Claude, I think this is likely a string matching problem)
I'd also like to invert the behaviour - submit command on shift-enter, and just keep typing, indenting, etc. on plain enter...
Yet another of the many issues with running Claude Code CLI on Windows. Any chance some work can be done at cleaning these things up?
I am seeing the same contradiction mentioned in the OP: the CLI claims Windows Terminal is not supported while simultaneously recommending it.
More importantly, this points to a larger User Experience issue regarding cross platform parity. Currently, the multi line shortcut is inconsistent ($Shift + Enter$ on macOS vs $Ctrl + Enter$ on Windows). For developers working in hybrid environments, this shortcut fragmentation is a constant source of friction.
Why this matters:
It would be great to see
/terminal-setupfixed for Windows Terminal and a move toward $Shift + Enter$ as the unified newline standard across Mac, Windows, and Linux.I really wish this could just be fixed.
Seems like the fix is widely known, yet no one does it.
Windows Terminal 1.25 now supports KITTY which should make this fixable: https://github.com/microsoft/terminal/pull/19817 (Not the error message itself, but the fact that it wasn't supported)
https://github.com/microsoft/terminal/releases/tag/v1.25.622.0
Root cause and workaround
Root cause
The terminal detection elsewhere in Claude Code correctly uses
$WT_SESSIONto identify Windows Terminal. However,/terminal-setupappears to rely on$TERM_PROGRAM, which Windows Terminal does not set:Because
$TERM_PROGRAMis empty, the command fails to identify the terminal and reports it as unsupported — even though$WT_SESSIONconfirms it is Windows Terminal.Suggested fix
Have
/terminal-setupcheck$WT_SESSION(in addition to or before$TERM_PROGRAM) when identifying Windows Terminal, consistent with the detection logic used elsewhere in the codebase.Manual workaround (confirmed working)
Add this to the
actionsarray in Windows Terminal'ssettings.json(Ctrl+Shift+,to open):Windows Terminal auto-normalises this into its newer split schema: the command definition stays in
actionsand the key assignment moves tokeybindings.Environment: Windows 11 Enterprise ARM64, Windows Terminal, Claude Code v2.1.86.
(Closing #41069 as duplicate of this issue.)
The
/terminal-setupcommand's error message is confusing — it says Windows Terminal isn't supported while simultaneously suggesting you use it.What's actually happening:
/terminal-setupcan't auto-configure Windows Terminal because its settings are in a JSON file that requires different handling than Unix terminal configs. But you can configure it manually:Manual setup for Windows Terminal:
Ctrl+,→ "Open JSON file" at the bottom left)For optimal Claude Code experience in Windows Terminal:
The Nerd Font is recommended for proper icon rendering in Claude Code's TUI.
Can confirm that @ElSensei503 's workaround works for me.
And can confirm that I am currently experiencing this weird bug where Claude Code simultaneously tells me "windows-terminal" cannot be used but that instead I should use "Windows Terminal."
I can also confirm @ElSensei503 's approach is fixing the issue.
Claude Code itself still gives incorrect information. It says:
This is incorrect. You have to edit the .json file manually, and it's not in an obvious location.
Claude confirms the lack of it's own answer:
My setup: Take Command (TCC) from JPSoft. Windows power shell or CMD in a pinch. I use Visual Studio.
So what I did, was open Visual Studio, File/Open
%LOCALAPPDATA%\Packages\Microsoft.WindowsTerminal_8wekyb3d8bbwe\LocalState\,then paste in the mentioned text at the top:Visual Studio will look at the schema, and change the pasted text to:
and add a line further down for:
I usually use TCMD (Take Command from JPSoft), so I don't screw with Windows Terminal much, but Claude shouldn't paste incorrect information. Even better, installing claude code should make the change or suggest it.
Clearly, WIndows is a redheaded stepchild, and it's frustrating. Do I have to mention market share?
@sosukesuzuki this is not fixed. Please reopen
I just installed and tried claude code for the first time, and shift enter does not work.. the message after
/terminal-setupis not useful either, and badly indented:<img width="1428" height="396" alt="Image" src="https://github.com/user-attachments/assets/3492f981-1b3f-40bf-88a7-e6478cdd3ddf" />