# How to get a sound when Claude Code finishes

Hear when Claude Code is done or needs you. Use its built-in hooks with a macOS sound, or let TapNoise connect it for you in Settings > Agents.

By [Rudra Satani](https://tapnoise.com/about/#maker), who makes TapNoise · 9 October 2026 · Updated 8 November 2026

In this post

Give Claude Code a task and switch to another window, and the hard part is noticing when it has finished or is waiting for your answer. There are two routes: set up Claude Code’s own hooks yourself, or let TapNoise connect it for you.

## The built-in route: Claude Code hooks

Claude Code can run a command of your choice at set moments. These are called hooks, and you set them in a settings file. For your own account, that file is `~/.claude/settings.json`.

Two events matter here:

- **`Stop`** fires when Claude finishes responding. It has no matcher, so it fires every time.

- **`Notification`** fires when Claude sends a notification. It supports matchers, such as `permission_prompt`, which means Claude is waiting for you to approve something.

A command hook for `Stop` looks like this:

`{  "hooks": {  "Stop": [  {  "hooks": [  { "type": "command", "command": "afplay /System/Library/Sounds/Glass.aiff" }  ]  }  ]  } }` 

`afplay` is a command that ships with macOS, and `Glass.aiff` is one of the system sounds in `/System/Library/Sounds`. You can point the command at any sound file. To get a notification instead, use `osascript -e 'display notification "Claude is done"'`.

Two cautions. If `settings.json` already has content, add the `Stop` entry inside the existing `hooks` object rather than replacing the file, and keep a backup. A stray comma will stop the file from parsing. Also check the current hook documentation on Claude Code’s site, since the format can change.

## The easier route: TapNoise

[TapNoise](https://tapnoise.com/download/) is a menu bar app with Agent Sounds. It plays a short cue when Claude Code finishes, when it needs you, or when a turn fails, in the sound theme you picked. Tappy, the keycap on your desktop, reacts to each one too.

1. Open TapNoise Settings and go to **Agents**.

1. Under **Connect your agents**, click **Connect** next to Claude Code.

1. Restart Claude Code if it was already running. TapNoise notes that running agents pick up changes only after a restart.

Connecting edits your settings file in a limited way. TapNoise adds its own entries to the Stop, Notification (with the `permission_prompt` matcher) and StopFailure lists, placed after any hooks you already have. It leaves everything else in the file alone. It backs up the file first to `~/Library/Application Support/TapNoise/Agent hook backups`. Clicking **Remove** takes TapNoise’s entries out again.

The hook sends only the agent’s name, whether it is done, needs you or hit an error, and the app it runs in. The Agents page has a “What TapNoise writes to” section that shows the exact entry before you connect.

Two more things in the same place:

- **Play agent sounds** turns the cues on or off.

- **Knock twice to answer** brings a waiting agent’s window forward. Knocks need an Apple silicon MacBook, as the Agents page says.

The Agents page is part of the license, so you need an activated copy of TapNoise to use it. A one-time purchase is US$14.99 for one Mac or US$20.99 for two, plus tax, with a 7-day money-back guarantee for standard purchases. [Diwali Solo offer orders are final sale](https://tapnoise.com/refunds/#diwali), subject to statutory rights and Dodo buyer terms.

## Which one to pick

If you like to edit settings files, the hooks route costs nothing and needs only macOS. If you would rather not touch JSON, TapNoise connects Claude Code in one click, removes its entries in one click, and keeps a backup. Either way, the sound plays when Claude stops, which is the moment you were waiting for.

If you use Codex or Cursor too, the same Agents page connects them. See [how to know when Codex is done](https://tapnoise.com/blog/know-when-codex-is-done/) for Codex.

**About the author**

Rudra Satani makes TapNoise. Spotted a mistake? Email [support@tapnoise.com](mailto:support@tapnoise.com?subject=Blog%20correction), or reach out at [@rudraxx13](https://x.com/rudraxx13).

## Related guides

- [**Connect Claude Code, Codex and Cursor**Connect Claude Code, Codex or Cursor in Settings › Agents to hear when they finish or need you. TapNoise backs up each agent's settings first.](https://tapnoise.com/docs/connect-coding-agents/)

## Hear TapNoise on your Mac

Every sound is made by TapNoise itself. Try the sounds on the homepage first, then download the app.

[Download TapNoise](https://tapnoise.com/download/) · [Try the sounds](https://tapnoise.com/#try)

## More from the blog

- [**How to know when Codex is done on your Mac**Codex can run a command when a turn ends. Set that up yourself, or let TapNoise connect Codex in Settings > Agents and play a sound when it finishes.](https://tapnoise.com/blog/know-when-codex-is-done/)

- [**Agent sounds not working on Mac? Check these layers**Separate audio playback, quiet mode, connection state and agent event delivery before editing hook files or reconnecting every coding tool.](https://tapnoise.com/blog/debug-missing-agent-sounds-mac/)

- [**An agent done sound does not mean the code is correct**Interpret coding-agent completion cues as a signal to review, then check the diff, tests and remaining work before treating a turn as successful.](https://tapnoise.com/blog/agent-done-sound-vs-success/)

- [**Different Terminal sounds for success and failure on Mac**Save a command's exit status, play a distinct local cue for each outcome and return the original status so the notification cannot disguise a failed build.](https://tapnoise.com/blog/terminal-sound-success-failure/)

Source: https://tapnoise.com/blog/claude-code-sound-when-done/
