InstantPing

InstantPing / Guides

Claude Code notifications on Windows: toast popup and sound

Updated 2026-12-04

On Windows, the cleanest Claude Code notification is a toast popup in the corner of the screen. You need a small PowerShell script and a Stop hook that runs it. One detail matters: toasts sent under the generic "Windows PowerShell" name are silently dropped on some PCs, so the script below registers its own app name.

Step 1: save the script

Save this as C:\Users\you\claude-notify.ps1. It is adapted from the script InstantPing uses on Windows.

param([string]$Title = "Claude Code", [string]$Body = "Claude is done")
$id = "ClaudeNotify"
$k = "HKCU:\Software\Classes\AppUserModelId\$id"
if (-not (Test-Path $k)) { New-Item $k -Force | Out-Null }
New-ItemProperty $k -Name DisplayName -Value "Claude Notify" -PropertyType String -Force | Out-Null
New-ItemProperty $k -Name ShowInSettings -Value 1 -PropertyType DWord -Force | Out-Null
[void][Windows.UI.Notifications.ToastNotificationManager, Windows.UI.Notifications, ContentType = WindowsRuntime]
$x = [Windows.UI.Notifications.ToastNotificationManager]::GetTemplateContent(1)
$t = $x.GetElementsByTagName("text")
[void]$t.Item(0).AppendChild($x.CreateTextNode($Title))
[void]$t.Item(1).AppendChild($x.CreateTextNode($Body))
[Windows.UI.Notifications.ToastNotificationManager]::CreateToastNotifier($id).Show([Windows.UI.Notifications.ToastNotification]::new($x))
Start-Sleep -Seconds 3

The script registers a per-user app name (no admin rights needed), so "Claude Notify" also shows up in Windows notification settings where you can control it. The final Start-Sleep matters: Windows shows the toast asynchronously, and a process that exits at once can drop it.

Step 2: add the hook

In %USERPROFILE%\.claude\settings.json:

{
  "hooks": {
    "Stop": [
      { "hooks": [ { "type": "command", "command": "powershell -NoProfile -ExecutionPolicy Bypass -File C:/Users/you/claude-notify.ps1 -Body \"Claude is done\"" } ] }
    ]
  }
}

Add the same block under "Notification" with the body "Claude is waiting for you" to also get told when Claude asks a question. Restart your Claude Code session so the settings load.

The catch: hooks block

Claude Code waits for a hook to finish, and this script takes about three seconds. That delay is added to every reply. The fix is to start the script as a detached background process and return at once, which needs a small wrapper. InstantPing does exactly that, and also skips tasks under 15 seconds.

If no toast appears

Frequently asked questions

How do I get a Windows notification when Claude Code is done?

Save a PowerShell toast script, then add a Stop hook in %USERPROFILE%\.claude\settings.json that runs it with powershell -File. The full script and hook are above.

Why does my Windows toast not show up?

Toasts sent under the generic Windows PowerShell name are dropped on some PCs. Registering your own app name under HKCU, as the script above does, avoids that. Also check Focus Assist and the app's notification settings.

Does the PowerShell hook slow down Claude Code?

Yes, by the time the script runs (about three seconds here), because Claude Code waits for hooks to finish. Run the toast as a detached background process to avoid the delay.