How to Uninstall Hooks in AI Agents on Mac (Complete Guide)

Complete guide to locating, inspecting, and uninstalling hooks across Codex, Claude Code, Cursor, Gemini CLI, Windsurf, Copilot, Antigravity, Devin, and 110+ AI tools on macOS.

AI Agent bar · Updated

Modern AI coding assistants can execute background hooks loaded from user dotfolders, project repositories, or system-wide policy files—rarely surfacing those entries inside the main chat window.

What Hooks Do in AI Coding Agents

An AI agent hook is an event-driven rule configured to run external scripts whenever prompts are submitted, tools or terminal commands execute, or files are read or modified. On macOS, hooks typically fall into two categories:

  1. Self Configured: Workflow scripts added by you (such as code formatters or completion notifications).
  2. Admin Installed: System-level rules placed by enterprise endpoint or device-management software in protected directories outside your home folder.

Overview of hooks across Codex, Claude, and Cursor in AI Agent bar

Hook Configuration Locations by AI Agent

AI Agent Common Personal Config Path One-Click Removal with AI Agent bar
OpenAI Codex ~/.codex/hooks.json Yes (Personal & Admin Installed)
Claude Code ~/.claude/settings.json Yes (Personal & Admin Installed)
Cursor ~/.cursor/hooks.json Yes (Personal & Admin Installed)
Gemini CLI ~/.gemini/settings.json Yes (Personal & Admin Installed)
Windsurf ~/.codeium/windsurf/hooks.json Yes (Personal & Admin Installed)
GitHub Copilot CLI .github/hooks/*.json · ~/.copilot/ Yes (Personal & Admin Installed)
Google Antigravity ~/.gemini/antigravity/ Yes (Personal & Admin Installed)
Devin ~/.devin/ Yes (Personal & Admin Installed)

Beyond deep hook inspection for these tools, AI Agent bar automatically detects over 110 local AI tools on macOS—including Cline, Kiro, OpenCode, Roo Code, Continue, Aider, Goose, Zed, Warp, and JetBrains AI.

Why One-Click Force Uninstall Beats Manual Editing

  • Multi-layered config files: A single assistant can merge hooks from repository folders, ~/.<tool>/, and /Library/Application Support/ or /etc/ at the same time.
  • Syntax fragility: A single invalid comma in a JSON or TOML configuration can break agent startup.
  • Silent background restore: Workplace endpoint software often watches system policy paths and restores deleted hooks within seconds.

Download AI Agent bar for Mac or review Pricing and the Desktop CLI reference.