anotifier / claude-code
Claude Code logo

anotifier: the Claude Code notifier for desktop, phone and Slack.

anotifier is a free, open-source Claude Code notifier. The moment Claude Code finishes a turn, asks for permission or waits for your input, it sends a desktop toast, a phone push, or a Slack, Discord or Telegram message, on Windows, macOS, Linux and WSL, in a terminal or in VS Code. Run the command below once (start Claude Code once first, so its settings file exists). Claude Code picks up the new hooks on its own; if /hooks doesn't list them, restart it.

$ npx anotifier@latest setup

Or install it as a Claude Code plugin, in two steps: /plugin marketplace add DevinoSolutions/anotifier-for-claude-codex-cursor then /plugin install anotifier@anotifier

[ HOW IT HOOKS IN ]

Wired into Claude Code itself.

Setup adds two hook entries to Claude Code's own ~/.claude/settings.json, plus a statusLine entry that routes the statusline through anotifier (1.5.0 and later). The hooks run inside Claude Code itself, with no wrapper process.

StopClaude Code finished its turnTitled my-app · Claude Code. On the toast and on webhooks the body is the start of Claude's last reply, up to 180 characters; phone push says my-app: Task complete unless you turn on rich content. If background tasks are still running, the alert waits for the real finish.
NotificationClaude Code needs youClaude's own message is the body, such as a permission request or a question, sent urgent when Claude is blocked on you. The idle reminder (“Claude is waiting for your input”) goes out at normal priority, because nothing is blocked.
[ THE OPTIONS ]

The ways to get Claude Code notifications.

Searching for a Claude Code notifier turns up five kinds of tool: Claude Code's own notifications, companion apps, native macOS tools, VS Code extensions, and hooks. Each suits someone. Facts about other projects come from their own pages, linked below, and may have changed since 2026-10-15.

OptionGood forWhere it stops
Claude Code's built-in notificationsNo setup. By default Claude Code sends a desktop notification only in Ghostty, Kitty and iTerm2, and preferredNotifChannel set to terminal_bell rings the bell in other terminals (Claude Code docs).A desktop notification or a bell on the machine running Claude Code. Phone push needs Remote Control and the Claude mobile app, and in the 'Push when Claude decides' mode Claude chooses when to send (docs).
Companion apps, such as Claude Code Notifier (claudecodenotifier.com)A macOS menu bar app with iOS and Android apps. Its page says you can approve permission requests and reply from your phone (mobile response needs iTerm2).The desktop app needs macOS 14 or later, and its page lists no Windows or Linux desktop app. Its mobile features are on a paid plan, per its pricing.
Native macOS tools, such as kovoor/claude-code-opencode-notifierMIT-licensed native macOS banners for Claude Code and OpenCode, showing which Ghostty tab or project raised them.macOS only, needs jq, and works best in Ghostty.
VS Code extensions, such as Claude Code Notifier (VS Code extension by Erdem Giray)Free. Different sounds and banners for permission, question and finished (off by default) events inside the VS Code window with the project open, and it installs its own hooks on first run. Per its listing it works over SSH, WSL and containers with a local companion extension.Built for VS Code: the banners come from the extension, so VS Code needs to be running.
Hooks you write yourselfFree, any OS, no extra software. The next section has a working pair.One command per OS and fixed text. Every extra (project name, what Claude said, phone push, priority) is a script you maintain.
anotifierOne command wires Stop and Notification hooks. Desktop toasts on Windows, macOS, Linux and WSL, phone push over ntfy with no account, Slack, Discord, Telegram or any webhook, and the same config for Codex CLI, Cursor and Gemini CLI. Free and open source (AGPL-3.0).A command-line tool with no menu bar app or GUI. It alerts you; you answer Claude in the terminal. Click-to-focus works on Windows only.

Pick by what you need to reach. One platform and one editor: a companion app or an extension may fit better. More than one OS, your phone or a chat channel, or more than one agent: a hook-based tool like anotifier covers them with one install. For how each hook option works, the Claude Code notification guide walks through them.

[ DO IT BY HAND ]

Set up a Claude Code notifier yourself.

Claude Code runs hooks: shell commands registered in a settings file. Your user settings file is ~/.claude/settings.json (%USERPROFILE%\.claude\settings.json on Windows), and it applies to every project. Stop fires when Claude finishes a turn; Notification fires when it is waiting for permission or input. This pair shows a macOS banner for both:

{
  "hooks": {
    "Stop": [
      {
        "hooks": [
          {
            "type": "command",
            "command": "osascript -e 'display notification \"Claude finished\" with title \"Claude Code\"'"
          }
        ]
      }
    ],
    "Notification": [
      {
        "matcher": "",
        "hooks": [
          {
            "type": "command",
            "command": "osascript -e 'display notification \"Claude needs your input\" with title \"Claude Code\"'"
          }
        ]
      }
    ]
  }
}

Swap in the command for your OS. Inside the JSON, write each double quote as \" (the macOS and Windows commands both contain some). The Windows one is the dialog box from Claude Code's own docs; it stays on screen until you click OK, so use it for Notification rather than Stop. On macOS, osascript notifications are attributed to Script Editor; if Script Editor is not allowed to send notifications, the command fails silently.

# macOS
osascript -e 'display notification "Claude finished" with title "Claude Code"'

# Linux (needs a notification daemon; on Debian/Ubuntu libnotify-bin provides notify-send)
notify-send 'Claude Code' 'Claude finished'

# Windows (PowerShell)
powershell.exe -Command "[System.Reflection.Assembly]::LoadWithPartialName('System.Windows.Forms'); [System.Windows.Forms.MessageBox]::Show('Claude finished', 'Claude Code')"
  • If the file already has a hooks key, add Stop and Notification next to the events already there rather than replacing the object. Type /hooks in Claude Code to check they registered.
  • The Notification hook with an empty matcher runs for every notification type. To alert only for approvals, set "matcher": "permission_prompt"; see the permission notifications guide.
  • Claude Code's documentation names ~/.claude/settings.json as the user settings file. If you set CLAUDE_CONFIG_DIR, Claude Code reads its settings from that folder instead.

What anotifier adds on top of this:

  • A useful message. The title names the project (my-app · Claude Code) and the toast carries the start of Claude's last reply or its question, instead of fixed text.
  • Phone and chat in the same hook, sent to every channel in parallel with a short timeout each, so a dead channel never holds Claude up.
  • Priorities. Permission prompts and questions go out urgent; the idle reminder and informational types go out at normal priority.
  • No double alerts. A repeat of the same event within 1.5 seconds is dropped.
  • Snooze and quiet hours, an uninstall that removes only its own entries, and a backup of settings.json before it edits.
  • Usage and context warnings through the statusline, covered below.
[ WHAT SETUP WRITES ]

Two hooks and a statusLine in ~/.claude/settings.json.

Setup only wires Claude Code when ~/.claude/settings.json already exists (on Windows, in the .claude folder of your user profile), so start Claude Code once first. It copies the file to ~/.anotifier/backups/, then adds this entry under Stop:

{
  "hooks": {
    "Stop": [
      {
        "hooks": [
          {
            "type": "command",
            "command": "node \"/path/to/anotifier/src/notify.mjs\" --source claude",
            "timeout": 10
          }
        ],
        "_managed_by": "anotifier",
        "matcher": ""
      }
    ]
  }
}

Notification gets an identical entry. The path points at the anotifier package on your machine, which is the npx cache if you ran it with npx. _managed_by is how status and uninstall tell anotifier's entries from your own hooks. Claude Code gives the hook 10 seconds; anotifier sends to every channel in parallel, each with a shorter timeout, and always exits cleanly, so a dead channel never holds Claude up.

From 1.5.0, setup also routes the statusline through anotifier, which is how usage-limit warnings (1.5.0) and context warnings (1.6.0) work. It adds this statusLine entry; the --wrap-b64 part appears only if you already had a statusline, and carries your old command, base64-encoded, so it keeps printing:

{
  "statusLine": {
    "type": "command",
    "command": "node \"…/anotifier/src/statusline.mjs\" --wrap-b64 <your old command, base64>"
  }
}

Installed as a plugin instead? The plugin registers the same two hooks from its own hooks.json, and /anotifier:setup wires your other agents. Plugin hooks don't show in anotifier status and anotifier uninstall doesn't remove them; remove the plugin from Claude Code's /plugin menu instead.

[ GOOD TO KNOW ]

What it does, and what it doesn't.

  • The ding comes from Claude Code itself. The hook hands Claude Code a bell to print in its own terminal (Claude Code 2.1.141 or newer), so no extra process has to find the right tab. To change the sound or turn it off, see the Claude Code notification sound guide.
  • Only types that wait on you are urgent. Permission prompts and questions go out urgent. Informational types such as agent_completed arrive at normal priority, and echoes of something you just did, such as auth_success, are dropped. The hook has no matcher; the permission notifications guide shows how to filter by type in a hook you write yourself.
  • Needs-input alerts stand out. They go out urgent, which raises the priority on ntfy and Linux notify-send, and toasts play a different sound than for a finished task.
  • Click-to-focus is Windows-only. Clicking the toast brings forward the window whose title contains the project folder. macOS, Linux and WSL toasts have no click action.
  • Snooze and quiet hours silence every channel, the bell included: npx anotifier@latest snooze 2h.
[ USAGE LIMITS ]

A warning before you hit a usage limit.

Version 1.5.0 and later warns you before Claude Code stops at a usage limit. One notification goes out as your 5-hour or weekly usage crosses 70%, 85% and 95%, at default, high and urgent priority. It names the chat, the window and when it resets. Usage belongs to your account, so each threshold warns once per window across all your chats.

  • Claude.ai Pro and Max only. Claude Code reports usage only to those plans, and only to the statusline command, never to hooks.
  • Setup routes your statusline through anotifier. anotifier setup points statusLine at src/statusline.mjs. A statusline you already have is wrapped and still prints your line; anotifier uninstall restores it exactly.
  • Toast, ntfy and webhook, never the bell. Snooze and quiet hours hold warnings back.
  • Configurable. usageAlerts: { "enabled": true, "thresholds": [70, 85, 95] } in ~/.anotifier/config.json.

The usage limit notifications guide has the statusline script to write yourself and the full details.

[ CONTEXT WARNING ]

A warning before Claude Code auto-compacts.

Version 1.6.0 and later sends one notification per chat when its context passes 85% of the auto-compact window, so you can wrap up or run /compact before Claude Code compacts on its own. It names the chat and the size, such as 174K of 200K tokens, at high priority.

  • Once per chat. A chat never warns twice, even after /compact. /clear starts a new session, which can warn again.
  • Measured against the auto-compact window, from CLAUDE_CODE_AUTO_COMPACT_WINDOW or your /autocompact setting, else the model's window. Skipped when auto-compact is off. The --autocompact flag and managed settings are invisible to a statusline, so the warning can be late or missing with them.
  • No subscription needed. It works on API-key and proxy sessions too, through the same statusline wiring as usage warnings.
  • Toast, ntfy and webhook, never the bell. Snooze and quiet hours hold it back.
  • Configurable. contextAlerts: { "enabled": true, "threshold": 85 } in ~/.anotifier/config.json.

The auto-compact warning guide explains how the window is resolved and has a statusline script to write yourself.

[ CHANNELS ]

Every channel you'd actually use.

[+] Desktop toasts macOS, Windows, Linux + WSL routing.
[+] Phone push Android & iOS via ntfy — no account.
[+] Webhooks Slack, Discord, Telegram, any HTTP endpoint.
[+] Terminal bell A ding in the terminal the agent runs in.
[+] Click-to-focus On Windows, a click on the toast brings the project's window forward.
[+] Zero npm dependencies Plain Node.js 18+, one shared config.
[ CHECK IT, UNDO IT ]

Test it, then keep it or remove it.

npx anotifier@latest test       # fire a test alert on every channel
npx anotifier@latest status     # show which agents and channels are set up
npx anotifier@latest doctor     # diagnose a channel that stays quiet
npx anotifier@latest uninstall  # remove the hooks setup added

test sends straight to your channels without going through Claude Code, so it proves the channels work. uninstall removes only the entries anotifier added and restores your statusline (1.5.0 and later), and setup keeps a copy of every file it changes in ~/.anotifier/backups/.

[ FAQ ]

Claude Code questions, answered.

What is the best Claude Code notifier?

It depends on what you need to reach. On macOS only, a companion app may feel more native. In VS Code only, an extension is closest to the editor. If you want one install that works on Windows, macOS, Linux and WSL, reaches your phone or Slack, and covers Codex CLI, Cursor and Gemini CLI from one config, anotifier is built for that. The Remote Control feature in Claude Code and its mobile app can also push to your phone if you use them. And if you want no extra software, two hooks you write yourself take about ten lines. The comparison above lists what each option does.

Is anotifier free?

Yes. It is free and open source under AGPL-3.0, with no account and no paid tier. It runs with npx and needs Node.js 18 or newer. Phone push goes through ntfy, which is also free and open source; use the public ntfy.sh server or your own.

Does it work on Windows and WSL?

Yes. On Windows the toast needs PowerShell 7 and the BurntToast module; anotifier setup installs BurntToast for your user. Inside WSL the toast goes to Windows through interop, as a plainer banner without the agent icon, a custom sound or click-to-focus, so run anotifier from the WSL shell where your Claude Code settings live. macOS and Linux work too, with osascript and notify-send. See the Windows and WSL guide.

Can anotifier warn me before Claude Code auto-compacts?

Yes, from anotifier 1.6.0. It sends one notification per chat when its context passes 85% of the auto-compact window, so you can wrap up or /compact first. It works on API-key and proxy sessions too, not only Pro and Max. It reads the numbers from Claude Code's statusline, which anotifier setup routes through anotifier. See the auto-compact warning guide.

Can anotifier warn me before Claude Code hits a usage limit?

Yes, from anotifier 1.5.0 on a Claude.ai Pro or Max plan. It sends one notification when your 5-hour or weekly usage crosses 70%, 85% and 95%, naming the chat and when the window resets. It reads the numbers from Claude Code's statusline, which anotifier setup routes through anotifier and wraps around any statusline you already have. See the usage limit notifications guide.

How does anotifier integrate with Claude Code?

It uses Claude Code's native hooks. anotifier setup detects Claude Code and registers Stop and Notification hooks in ~/.claude/settings.json, after backing the file up. When Claude Code finishes a turn or asks for input, the hook fires and anotifier routes it to your channels.

Does it work with Claude Code inside VS Code?

Yes. The hooks live in Claude Code's own settings, so they fire the same way in a terminal and in the VS Code extension. On Windows, clicking the toast brings forward the window whose title contains the project folder.

What does a Claude Code notification say?

The title names the project and the agent, like my-app · Claude Code. On the toast and on webhooks the body is what Claude last said, or its question, trimmed to about 180 characters. Phone push through ntfy says my-app: Task complete unless you set ntfy.richContent to true.

Can I get Claude Code alerts on my phone?

Yes — phone push works over ntfy on Android and iOS with no account. Your phone buzzes when Claude finishes, even if you've walked away from the desk.

Is my code or conversation sent anywhere?

Nothing goes to us unless you opt in to error reports. An alert goes only to the channels you set up: by default the toast and any webhook get the start of Claude's last message, and ntfy gets a generic line. Separately, anotifier asks the npm registry for the latest version at most once a day; set updateCheck.enabled to false to stop that.

How do I remove it?

Run npx anotifier@latest uninstall. It removes anotifier's two entries, puts your original statusline back (or removes the one setup added), and leaves your own hooks in place. If you installed the plugin, remove it from Claude Code's /plugin menu as well.

[ GUIDES ]

Every option, explained.

[ ALSO WORKS WITH ]

One config, every agent.

Every command and config key is in the docs.

Full feature tour, demo video, and install options on the anotifier home page.