Stop hook does not fire in VS Code / VSCodium extension mode

Resolved 💬 3 comments Opened Apr 17, 2026 by daviddelven Closed May 25, 2026

Summary

The Stop hook defined in settings.json never executes when Claude Code runs as a VS Code / VSCodium extension. The same hook works correctly in CLI mode (claude from terminal).

Environment

  • Claude Code version: latest (VSCodium extension)
  • OS: Windows 11 Home 10.0.26200
  • Shell: PowerShell / bash

Configuration (settings.json)

{
  "hooks": {
    "Stop": [
      {
        "hooks": [
          {
            "type": "command",
            "command": "powershell.exe -NoProfile -ExecutionPolicy Bypass -Command \"& ~/.claude/hooks/stop-memory.ps1\"",
            "timeout": 60
          }
        ]
      }
    ]
  }
}

Verification method

Added a debug log as the very first executable line of the hook script (before any logic that could fail):

"$(Get-Date) invoked" | Out-File -Append "C:\Users\david\AppData\Local\Temp\stop-debug.txt"

After multiple conversation turns in the extension, the file was never created — confirming the script is never invoked at all.

Other hooks for comparison

  • SessionStart → works correctly in extension mode
  • PreCompact → works correctly in extension mode
  • Stop → never fires in extension mode

Expected behavior

Stop should fire after each assistant response turn, as documented, regardless of whether Claude Code runs as CLI or IDE extension.

Workaround

Run claude from the integrated terminal instead of using the extension chat panel.

View original on GitHub ↗

This issue has 3 comments on GitHub. Read the full discussion on GitHub ↗