[BUG] Ctrl+W, Shift+Tab, Alt+V stopped working in Claude Code on Windows (regression)

Status Fixed / completed
Reported on v2.1.83
Maintainer reply ✓ Yes — ashwin-ant
Activity 5 comments · opened Mar 25, 2026 · closed Apr 19, 2026
💡 Likely answer: A maintainer (ashwin-ant, collaborator) responded on this thread — see the highlighted reply below.

Description

Several readline/terminal keybindings stopped working inside Claude Code's TUI on Windows. They worked until approximately one week ago (around v2.1.7x).

Key finding: Ctrl+W works in Git Bash inside VS Code's integrated terminal before launching Claude Code, but stops working after Claude Code starts. This confirms the issue is in Claude Code's TUI input handler, not VS Code or the terminal emulator.

Affected Keys

| Key | Expected behavior | Actual behavior |
|---|---|---|
| Ctrl+W | Delete previous word (readline) | Nothing happens — keystroke is swallowed |
| Shift+Tab | Pass through to shell | Captured by chat:cycleMode (new default?) |
| Alt+V | Pass through to shell | Captured by chat:imagePaste |
| Ctrl+C | Interrupt / expected terminal behavior | Inconsistent behavior |

Steps to Reproduce

  1. Open VS Code with Git Bash as integrated terminal
  2. In the terminal, type some text and press Ctrl+W — it deletes the previous word ✓
  3. Run claude in the same terminal
  4. Type some text in the Claude Code chat input
  5. Press Ctrl+W — nothing happens ✗

Expected Behavior

Ctrl+W should delete the previous word in the chat input, as it does in any readline-based terminal input. Keys not bound to Claude Code actions should pass through to standard text editing.

Context

  • This is a regression — these keys worked ~1 week ago
  • Related to #22626 (unbinding keys via null swallows keystrokes instead of passing through)
  • Related to #29931 (Ctrl+B passthrough blocked)
  • Related to #38354 (Ctrl+W word boundary issues — different bug, that one is about Bun's Intl.Segmenter)

Environment

  • Claude Code: 2.1.83
  • Claude Code VS Code extension: 2.1.83
  • VS Code: 1.113.0
  • OS: Windows 10 Pro 10.0.19045 (running in Parallels VM on macOS)
  • Shell: Git Bash
  • Terminal: VS Code integrated terminal

View original on GitHub ↗

5 Comments

bcchriscooper-Trader · 5 months ago

Adding more affected keys from a separate Windows setup:

Additional affected keys (VS Code integrated terminal only):
| Key | Expected behavior | Actual behavior |
|---|---|---|
| Escape | Dismiss submenus / chat:cancel | Nothing happens |
| Numpad Enter | Submit input (same as Enter) | Nothing happens |
| Shift+Tab | Cycle mode / chat:cycleMode | Nothing happens |
| Alt+V | chat:imagePaste | Nothing happens |

Key finding: All of these work correctly when running Claude Code in standalone PowerShell — the issue is only in VS Code's integrated terminal. This further confirms the problem is in the VS Code extension / terminal interaction layer, not the core TUI.

Environment:

  • Claude Code: latest
  • OS: Windows 10 Home 10.0.19045
  • Shell: bash (VS Code integrated terminal)
  • Works fine in: standalone PowerShell
bryanils · 5 months ago

Sorry to spam but this is my environment and I'm closing my issue as this was an earlier one

What's Wrong?
Bug Report: Keyboard Input Regressions in VS Code Terminal (v2.1.83-2.1.84)

Environment

OS: Windows 10

WSL: WSL2

Terminal: VS Code integrated terminal (latest)

Claude Code: 2.1.83, 2.1.84

Problem Summary

Multiple keyboard input issues specific to VS Code integrated terminal in Claude Code versions 2.1.83 and 2.1.84.

Issue 1: Critical Input Failure — PARTIALLY RESOLVED

Basic keys (Space, Backspace, Enter, Control) were non-functional. Fixed by updating VS Code to latest version.

Issue 2: Shift+Tab Mode Cycling — BROKEN

Expected: Shift+Tab cycles through Normal → Auto-Accept → Plan Mode

Actual: No response, mode indicator does not appear, input completely ignored

Issue 3: Escape Key — BROKEN

Expected: Escape stops running agent or clears current input

Actual: No response, agent continues running, input not cleared

Verification

/plan slash command: works

Ctrl+C to stop agent: works

Standard Ubuntu terminal (WSL): Shift+Tab and Escape work correctly

VS Code integrated terminal: Shift+Tab and Escape broken

Steps to Reproduce

Install Claude Code 2.1.84 in WSL2 on Windows 10

Open VS Code integrated terminal (latest version)

Run claude

Press Shift+Tab to cycle modes — no response

Start an agent task, press Escape to stop — no response

Type in input box, press Escape to clear — no response

Regression Confirmation

2.1.82 and earlier: all keyboard functions work in VS Code terminal

2.1.83-84: Shift+Tab and Escape broken in VS Code terminal only

Workarounds

Use /plan slash command to enter plan mode

Use Ctrl+C to stop running agent

No workaround for clearing input box

System Info

uname -a: Linux DESKTOP-EQ55Q8H 6.6.87.1-microsoft-standard-WSL2 #1 SMP PREEMPT_DYNAMIC Mon Apr 21 17:08:54 UTC 2025 x86_64 x86_64 x86_64 GNU/Linux

Claude Code: 2.1.84

bryanils · 5 months ago
I had a similar issue and was able to resolve it by running /terminal-setup from the VSCode Claude Code window.

So do you mean when using claude code in the vscode plugin or extension? I generally don't use that, I find it runs faster and better using my WSL2 terminal opened inside VSCode.

I know this probably makes things a bit harder but that's how I like it.

ashwin-ant collaborator · 4 months ago

This was fixed in v2.1.85 — Restored terminal allowlist for Kitty keyboard protocol so VS Code integrated terminal (xterm.js) and SSH sessions no longer get pushed into enhanced keyboard mode, fixing ESC/Ctrl+C/Shift+Tab/Ctrl+W being swallowed on Windows. If you're still seeing this in the latest version, please comment with your version and repro and we'll reopen.

github-actions[bot] · 4 months ago

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.