Add setting to disable terminal auto-focus in VS Code extension
Problem
When running Claude Code from an external terminal (e.g. Ghostty) with the VS Code extension connected for IDE integration, the terminal panel in VS Code pops up repeatedly during a session. This happens because the extension calls terminal.show() unconditionally after certain MCP tool operations (diff views, tab management, file operations, etc.).
There is no setting to disable this behavior. The existing VS Code setting terminal.integrated.focusAfterRun has no effect since the focus is triggered by the extension itself.
Expected behavior
A setting like claudeCode.terminalAutoFocus (default true) that can be set to false to prevent the extension from calling terminal.show() after IDE operations — especially when Claude Code is running in an external terminal rather than in VS Code's integrated terminal.
Environment
- Platform: macOS (Darwin 25.2.0, arm64)
- Terminal: Ghostty (external, not VS Code integrated terminal)
- Claude Code Extension: 2.1.34
- Claude Code preferred location: sidebar
4 Comments
Found 3 possible duplicate issues:
This issue will be automatically closed as a duplicate in 3 days.
🤖 Generated with Claude Code
Additional debugging
Confirmed this is caused by the Claude Code VS Code extension itself, not any specific setting or plugin.
Steps to reproduce
What was ruled out
terminal.integrated.focusAfterRun: "none"— already set, no effectterminal.integrated.environmentChangesRelaunch— unchecked, no effectStophook) — disabled, still happens/idedisconnect) — disconnected, still happensConclusion
The extension runs background activity that reveals the terminal panel on every conversation turn, even when:
This only affects users running Claude Code from an external terminal while having the extension installed.
Wow, just came across this. Claude must have posted this while troubleshooting.
In any case, issue went away after reinstalling the CC plugin.
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.