Extend keyboard support to more terminals
CHANGELOG · original
Improved keyboard support over SSH and in unrecognized terminals: terminals that answer the kitty keyboard query (such as foot and Alacritty 0.16+) now get Shift+Enter and Ctrl+Shift shortcuts Open official changelog ↗ Documentation
Documentation excerpt
Enter multiline prompts
Pressing Enter submits your message. To add a line break without submitting, press Ctrl+J, or type \ and then press Enter. Both work in every terminal with no setup.
In most terminals you can also press Shift+Enter, but support varies by terminal emulator:
| Terminal | Shift+Enter for newline |
|---|---|
| Ghostty, Kitty, iTerm2, WezTerm, Warp, Apple Terminal, Windows Terminal | Works without setup |
| Other terminals that support the kitty keyboard protocol, such as foot and Alacritty 0.16 or later | Works without setup. Requires Claude Code v2.1.269 or later |
| VS Code, Cursor, Devin Desktop, Alacritty before 0.16, Zed | Run /terminal-setup once |
| gnome-terminal, JetBrains IDEs such as PyCharm and Android Studio | Not available; use Ctrl+J or \ then Enter |
For VS Code, Cursor, Devin Desktop, Alacritty before 0.16, and Zed, /terminal-setup writes a Shift+Enter keybinding into the terminal's configuration file. On the first run you see a confirmation such as Installed VSCode terminal Shift+Enter key binding. Existing bindings are left in place; if you see a message such as VSCode terminal Shift+Enter key binding already configured, no change was made. Run /terminal-setup directly in the host terminal rather than inside tmux or screen, since it needs to write to the host terminal's configuration.
In VS Code, Cursor, and Devin Desktop, /terminal-setup also updates two editor settings: it sets terminal.integrated.gpuAcceleration to "off" to prevent garbled text in the integrated terminal, and it sets terminal.integrated.mouseWheelScrollSensitivity for smoother scrolling in fullscreen mode. To undo the GPU acceleration change, set it back to "auto" and reload the editor window.
In Zed, /terminal-setup updates your keymap.json in place:
- If the keymap already has bindings and none of them is a Terminal
shift-enter, Claude Code first backs it up to a copy in the same directory, such askeymap.json.1a2b3c4d.bak, then merges the Shift+Enter binding into your keymap, keeping your other keybindings and comments - If Claude Code can't read or parse the keymap, can't back it up, or can't verify the merged result, it leaves the file unchanged and prints the keybinding block to add yourself
If you are running inside tmux, Shift+Enter also requires the tmux configuration below even when the outer terminal supports it.
To bind newline to a different key, or to swap behavior so Enter inserts a newline and Shift+Enter submits, map the chat:newline and chat:submit actions in your keybindings file.
Documentation snapshot · 2026-09-23