Disable Claude Code Edit Confirmation Popup | Generated by AI
To disable the edit confirmation popup in Claude Code (so it just applies edits directly to files like sync_githook.py without asking), you need to configure the permissions in your settings.json file. This is the “Claude Code JSON” you’re referring to—it’s Claude Code’s main settings file for user-level configs.
Steps to Set It Up
- Locate or Create the File:
- The file is at
~/.claude/settings.json(on macOS/Linux) or%USERPROFILE%\.claude\settings.json(on Windows). The.claudefolder is hidden, so use your terminal/file explorer to navigate there. - If the file or folder doesn’t exist, create them. You can do this by running Claude Code’s
/configcommand in its interactive REPL (it’ll guide you to open the settings interface).
- The file is at
- Edit the JSON:
- Open
settings.jsonin any text editor (e.g., VS Code). -
Add or update the
permissionssection to auto-approve edits. Here’s a simple config to disable prompts for all edit actions:{ "permissions": { "defaultMode": "acceptEdits", "allow": [ "Edit(*)", "Write(*)", "MultiEdit(*)" ], "ask": [] } }- What this does:
"defaultMode": "acceptEdits": Sets the global default to accept edits without prompting."allow": Pre-approves specific tools likeEdit(for single-file edits),Write(for writing content), andMultiEdit(for batch changes) for any files (*wildcard)."ask": []: Ensures no actions trigger a prompt unless explicitly denied elsewhere.
- Save the file. Changes apply immediately in your next Claude Code session.
- What this does:
- Open
- Test It:
- Restart Claude Code or reload the session.
- Ask it to edit a file (e.g., “Edit sync_githook.py to add a comment”). It should apply the change without the popup.
- If you want project-specific settings (e.g., only for this repo), create
.claude/settings.jsonin your project’s root folder instead.
- Optional Tweaks:
- For more granular control (e.g., only allow edits in certain directories): Change
"Edit(*)"to"Edit(./src/**)". - If prompts persist, run
/allowed-toolsin the REPL to check current rules, or use/configto tweak via the UI. - For security, avoid overly broad
allowrules—start simple and expand.
- For more granular control (e.g., only allow edits in certain directories): Change
This should make your workflow faster without interruptions. If you’re in an enterprise setup, check with your admin, as managed policies might override user settings.
Claude Code Settings Docs
Disable Claude Code Permission Prompts Guide
```