Remove Hook

VerifiedSafe

Removes a specific hook from the project's Claude settings. It first lists hooks, then asks the user to confirm which hook to remove, deletes it, and reports the result. Useful when you want to clean up or correct hook configurations without manual file editing.

Sby Skills Guide Bot
DevelopmentIntermediate
6/2/2026
Claude Code
#hooks#removal#configuration#claude-code

Recommended for

Automated summary

Removes a hook from the Claude Code project configuration, with user confirmation before deletion.

Strengths

  • Safe deletion with confirmation
  • Handles both settings.json and settings.local.json
  • Maintains JSON formatting
  • Displays hook count after removal

Limitations

  • Only removes one hook at a time
  • Requires user to know hook details (event, number, source)
  • Only works for Claude Code hooks
When to use it

When you need to remove a specific hook from your Claude Code configuration.

When not to use it

When you want to bulk delete hooks or modify hooks non-destructively.

Security analysis

Safe
Quality score92/100

This skill only reads and writes JSON configuration files within the project's .claude directory. It requires explicit user confirmation before deletion, uses no shell commands or network access, and poses no destructive or exfiltration risk.

No concerns found

How this analysis is made

Examples

Remove a hook with trigger phrase in Japanese
フックを削除してください
Remove specific hook by details
Remove the PreToolUse hook for the Write matcher from settings.local.json

name: remove-hook description: プロジェクトからフックを削除する。「フック削除」「フックを消して」「hook を削除」「フックを外して」「フック解除」「hook 削除」「フックを取り除いて」などで起動。 allowed-tools: [Read, Write, AskUserQuestion]

Remove Hook

プロジェクトからフックを削除します。

実行手順

  1. まず list-hooks スキルと同様にフック一覧を表示
  2. ユーザーに削除対象を確認:
    • イベント名(例: PreToolUse)
    • フック番号(例: 1)
    • ソースファイル(settings.json または settings.local.json)
  3. 確認後、該当するフックを削除
  4. 削除完了メッセージを表示

削除確認フォーマット

## フック削除

以下のフックを削除しますか?

| 項目 | 値 |
|------|-----|
| イベント | PreToolUse |
| マッチャー | Write |
| タイプ | command |
| コマンド | prettier --write "$FILE" |
| ソース | settings.json |

削除を実行する場合は「はい」と入力してください。

削除処理

  1. 対象ファイル(.claude/settings.json または .claude/settings.local.json)を読み込み
  2. hooks セクションから該当エントリを削除
  3. フック配列が空になった場合はイベントキーごと削除
  4. hooks オブジェクトが空になった場合は hooks キーごと削除
  5. ファイルを保存

出力フォーマット(削除完了時)

## 削除完了

以下のフックを削除しました:

- イベント: PreToolUse
- マッチャー: Write
- ソース: settings.json

現在のフック数: 2件

重要な注意事項

  • ✅ 削除前に必ず確認を求める
  • ✅ settings.local.json のフックも削除可能
  • ✅ 削除後にフック数を表示
  • ✅ JSON フォーマットを維持(インデント等)
  • ❌ 複数フックの一括削除は行わない(1つずつ確認)

From the file to a first result

The download contains exactly the content displayed on this page. This copy may differ from the latest version in the source repository.

View the source and supporting files

This download contains SKILL.md only. Any scripts, references, templates and dependencies are not included. Get the required files from the source, preserving their directory structure, before continuing.

1. Download the file

Download SKILL.md

From the root of a test project, save the file as .skill-downloads/remove-hook-mma3jrgo/SKILL.md, or use the command below. This folder is for inspecting the skill before installation.

Command for macOS/Linux or WSL: requires a POSIX shell and curl. On Windows without WSL, use the download button and create the folder manually.

mkdir -p '.skill-downloads/remove-hook-mma3jrgo' && curl --fail --show-error --location 'https://skills-guides.com/api/skills/remove-hook-mma3jrgo/download' --output '.skill-downloads/remove-hook-mma3jrgo/SKILL.md.part' && mv '.skill-downloads/remove-hook-mma3jrgo/SKILL.md.part' '.skill-downloads/remove-hook-mma3jrgo/SKILL.md'

2. Check prerequisites

Read SKILL.md before using it. If it references scripts or external services, inspect them and prepare the required access in your test environment.

No recognized prerequisites section in this file. This does not mean it is self-contained: libraries, tools and access requirements may be mentioned elsewhere in the content or source repository.

The platforms on this page are catalog indications. The paths below follow tool documentation; they do not prove this skill has been run in those tools. No minimum tool version is confirmed for this listing.

3. Load the skill

After inspection, copy the complete folder into your project using one of the commands below, then open a new tool session. The command stops if a folder with the same name already exists: compare the files before replacing it.

Claude Code
test -f '.skill-downloads/remove-hook-mma3jrgo/SKILL.md' && test -s '.skill-downloads/remove-hook-mma3jrgo/SKILL.md' && mkdir -p '.claude/skills' && test ! -e '.claude/skills/remove-hook' && cp -R '.skill-downloads/remove-hook-mma3jrgo' '.claude/skills/remove-hook'

OpenSkills

OpenSkills must already be installed. The local install/read procedure is checked with OpenSkills 1.5.0, which requires Node.js ≥ 20.6.0. Catalog slugs are not resolved automatically.

Official OpenSkills installation
openskills install './.skill-downloads/remove-hook-mma3jrgo'

openskills read 'remove-hook-mma3jrgo'

Reading should display the installed file content and its base directory. It does not run the skill or install its dependencies.

For an agent that reads AGENTS.md, then sync the index. This command changes AGENTS.md: review the diff before using it.

openskills sync

Manual method or another tool: attach SKILL.md to a conversation, or open it in an agent that can read files. Include any required supporting resources. No universal folder is recognized by every tool.

4. Try a first task

Use a short, synthetic input: an API endpoint, a small document or an interface brief. In a new conversation, attach the file or give the agent its path, then adapt this request:

Read .skill-downloads/remove-hook-mma3jrgo/SKILL.md and apply its instructions to this example: [describe a test input]. Identify any missing files, dependencies or access. Produce the result requested by the skill without inventing data or running unreviewed scripts.

Expected result: output matching the skill instructions, or a precise list of missing prerequisites. A read confirmation alone does not validate a first use. If an external resource is unavailable, that path remains untested.

Related skills