Claude Code inserts a newline when it receives ESC + CR. /terminal-setup installs this for
iTerm2 and VS Code, not for Windows Terminal. Add it by hand.
In settings.json, which ctrl+shift+, opens:
"actions": [
{ "command": { "action": "sendInput", "input": "\u001b\r" }, "id": "User.newline" }
],
"keybindings": [
{ "id": "User.newline", "keys": "shift+enter" }
]Both halves are required, and the two ids must match.
Recent Windows Terminal versions split bindings in two. actions defines behavior and tags it
with an id. keybindings maps keys to that id. Built-in ids begin with Terminal.; ids
beginning with User. you define yourself.
Name an id in keybindings that no actions entry defines, and Windows Terminal resolves the
binding to nothing. Shift+Enter falls through to plain Enter. Nothing warns you.
stty raw -echo; timeout 5 cat -v; stty sane; echoPress Shift+Enter, then Enter, then Ctrl+J.
| Output for Shift+Enter | Meaning |
|---|---|
^[^M |
works |
^M |
no ESC sent |
| nothing | the terminal swallowed the key |
Enter prints ^M. Ctrl+J breaks the line, because cat -v leaves LF alone.
stty raw is essential. Canonical mode translates CR to LF before cat reads it, so a newline
appears whether or not the ESC arrived.
Run the capture inside your multiplexer, then again in a bare SSH shell. Matching output clears the multiplexer and points upstream.
Kitty CSI-u does nothing. Claude Code never requests the kitty keyboard protocol; it parses only
capability responses. Send ESC + CR.
Multiplexers forward ESC + CR. One that swallowed ESC would break Vim.
The hint may still read ctrl+j. Only /terminal-setup sets that flag, and it skips Windows
Terminal. The binding works regardless.
Backslash then Enter needs no config.