[BUG] Shift+Enter does NOT newline 🔥 — '/setup-terminal' creates binding but doesn't work (VSCode WSL Ubuntu)
Resolved 💬 16 comments Opened Jun 30, 2025 by michellepace Closed Aug 20, 2025
_It's a tiny bug given what Claude Code can do, but a 🔥 big problem._
Environment
- What: Claude Code
- Operating System: Windows 10 running VSCode WSL Ubuntu connection (same for Cursor)
- Terminal: Claude Code terminal
Bug Description
Shift+Enter does not create a new line in terminal
Steps to Reproduce
- Run
/terminal-setup - Restart VSCode (WSL Ubuntu connection)
- Confirm new binding is in ~/.config/Code/User/keybindings.json
```json
[
{
"key": "shift+enter",
"command": "workbench.action.terminal.sendSequence",
"args": {
"text": "\\\r\n"
},
"when": "terminalFocus"
}
]
```
- Ensure I am in the Claude terminal, run
claudefrom bash - Write "please work now", press shift+enter, this still submits the message and does not create a new line
Expected Behaviour
New line whilst writing in Claude code terminal
Actual Behaviour
Submits message and does not create new line
Additional Context
- "Alt+Enter" makes a new line
- "\" makes a new line
- "Shift+Enter"... doesn't make a new line
- Claude Code suggested the below, I tried both. Neither worked.
🔥 Main Issue: Commands to Skip Shell Setting
The keybinding exists but VSCode terminal is consuming the Shift+Enter keystroke before it reaches
your keybinding. You need to add the command to VSCode's "Commands to Skip Shell" setting.
🍀 Solution Steps:
"Commands to Skip Shell" explained:
When you press a key in VSCode's integrated terminal, there are two possible handlers:
1. The shell (bash, zsh, etc.) - handles the keystroke
2. VSCode - handles the keystroke via keybindings
By default, most keystrokes go to the shell first. "Commands to Skip Shell" tells VSCode:
"Don't send this keystroke to the shell, handle it with VSCode keybindings instead."
For your use case:
- Shift+Enter: You want VSCode to handle this (send \\\r\n for line continuation)
- Enter: You want the shell (Claude Code) to handle this (submit message)
Why you need "Commands to Skip Shell":
Without it:
1. You press Shift+Enter
2. Shell gets the keystroke first
3. Shell might ignore it or handle it differently
4. Your VSCode keybinding never fires
With it:
1. You press Shift+Enter
2. VSCode intercepts it before the shell sees it
3. VSCode runs your keybinding (workbench.action.terminal.sendSequence)
4. The sequence \\\r\n gets sent to the shell
5. Shell interprets this as "continue this line"
So adding "workbench.action.terminal.sendSequence" to Commands to Skip Shell should
make your Shift+Enter work for multi-line input while keeping Enter for submission.
16 Comments
+1 i have the exact same problem
This may be a dupe of https://github.com/anthropics/claude-code/issues/1262.
Try this instead:
Option+Enter always works for me on macOS, so I captured the keycodes and it sends an Escape (\^[) and a Linefeed (\u000A). Updating the keybinding above makes Shift+Enter work identically to Option+Enter in VSCode on macOS.
There's too much multi-line inconsistencies between platforms.
Claude Code on Windows: Says "Tip: Press Shift+Enter to send a multi-line message" but Shift+Enter actually doesn't work. Ctrl+Enter sends newline. Alt+Enter toggles fullscreen.
Claude Code on WSL terminal: Shift+Enter sends the message. Ctrl+Enter sends newline. Alt+Enter toggles fullscreen.
Claude Desktop on Windows: Ctrl+Enter sends the message. Shift+Enter and Alt+Enter sends newline.
Claude on Web: Ctrl+Enter sends the message. Shift+Enter and Alt+Enter sends newline.
Claude on VS Code with it's key bindings is another mess.
I would preffer that Enter just creates a newline. Just like this box editor here on GitHub.
And use Ctrl+Enter to send. Also, just like this box editor here on GitHub.
This is much more natural. Any text editor does a newline when Enter is pressed. This is what most people are used too.
Chat applications, like WhatApp broke that rule, reverting things. On WhatsApp, for example, Shift+Enter, Ctrl+Enter, Alt+Enter can be used for newline while Enter alone would send the message. I think this is bad UI design.
Thank you @sirmalloc for your suggestion. I tried it but I'm afraid it did not work. I'm stuck with "\" for new lines. But thank you.
OMG you're a GOD! Thank you so much!
That solved my problem on Windows + WSL + VSCode terminal
Fix working for Code on Fedora https://gist.github.com/ben-alkov/1329c25db38cf2ea7ae9ea7fdaf10d3a
Exactly the same solution mentioned here: https://github.com/anthropics/claude-code/issues/2754#issuecomment-3064554102
If you don't nuke all of the other SHIFT+ENTER mappings, it will not work.
same issue, still does not work with Windows Terminal (Powershell 7) and vscode. even with suggested changes in https://github.com/anthropics/claude-code/issues/2754#issuecomment-3064554102
What does this mean, exactly? Are you running claude-code in a separate Windows Terminal window/tab?
Hi @ben-alkov no I’m running Claude Code via
claudein my cursor terminal withzshas my shell. It’s just a detail I should not have included.🤔 Have you tried what's in the gist I posted (removing existing mappings for SHIFT+ENTER)?
Found 3 possible duplicate issues:
This issue will be automatically closed as a duplicate in 3 days.
🤖 Generated with Claude Code
This issue has been automatically closed as a duplicate of #1251.
If this is incorrect, please re-open this issue or create a new one.
🤖 Generated with Claude Code
This issue has been automatically locked since it was closed and has not had any activity for 7 days. If you're experiencing a similar issue, please file a new issue and reference this one if it's relevant.