Guides

Claude Code approvals and permission requests: answer them from one place without turning them off

As of , checked against the official docs.

You don’t have to turn Claude Code’s approval prompts off with --dangerously-skip-permissions to stop them getting in your way. Pick the permission mode that fits the job, put the safe commands you run often into allow rules, and answer what is left from one place instead of hunting for the terminal. This guide covers the six permission modes, why auto-approve is risky, how to write allow rules, and how to answer the remaining requests in one place.

What permission modes does Claude Code have?

A permission mode decides what Claude Code asks you about and what it just runs (official docs, as of November 2026).

Mode What it does
default (Manual) Runs reads without asking; prompts before file edits, shell commands and network access
acceptEdits Runs file edits in your working directory and common filesystem commands such as mkdir, mv and cp without prompting
plan Researches and proposes a plan; nothing is edited until you approve it
auto A classifier model reviews each action instead of you
dontAsk Denies every call that would otherwise prompt; for CI and scripts
bypassPermissions Runs everything without prompts; for isolated containers and VMs only

During a session, Shift+Tab cycles through default, acceptEdits and plan; at startup, pass a mode as in claude --permission-mode plan. Set the one you always want as permissions.defaultMode in a settings file. Since Claude Code 2.1.283, interactive terminal sessions start in auto mode.

Why is turning everything off with auto-approve risky?

claude --dangerously-skip-permissions is the same as bypassPermissions mode, the one people call YOLO mode. The official docs warn plainly.

  • Use it only in isolated environments, such as containers or VMs without internet access, where Claude Code cannot damage your host system.
  • It offers no protection against prompt injection or unintended actions: an instruction hidden in a file or a web page the agent reads can simply be carried out.
  • For far fewer prompts with safety checks still running, the docs point to auto mode, and say of that mode too that it reduces prompts but does not guarantee safety.

So the order is this: pick a mode, allow the safe commands you run often with rules, and answer only what is left yourself.

How do allow rules cut the number of prompts?

Type /permissions in a session to see the rules in force and which settings file each comes from. To write them by hand, put a block like this in a settings file; it is the official docs' example as it stands.

{
  "permissions": {
    "allow": [
      "Bash(npm run *)",
      "Bash(git commit *)"
    ],
    "deny": [
      "Bash(git push *)"
    ]
  }
}

With it, npm scripts and git commits run without asking, and commands that begin with git push are refused. Three things to know (permissions docs).

  • Rules are evaluated in the order deny, ask, allow. A narrow allow rule can't carve an exception out of a broad deny rule.
  • Put the * after the subcommand: Bash(git log *) allows only git log, while Bash(git *) allows every git command.
  • Choosing "Yes, and don't ask again" at a prompt saves a Bash command as a rule in that repository's .claude/settings.local.json.

How do you answer what is left from one place?

Rules or not, a command Claude Code hasn't seen still asks. The trouble is that the request shows only in that session's terminal, so with several sessions you first have to find which terminal has stopped. There are three ways.

  • Get an alert and go to that terminal. A Notification hook whose matcher is permission_prompt fires when a permission prompt has waited about six seconds.
  • Find it in agent view. In claude agents, attach to the session marked Needs input and answer there. It lists Claude Code's background sessions only.
  • Answer in Devalley. The resident of the session that needs approval comes to the middle of your screen with a "May I?" bubble. Click it to see what it wants to do (the command or the file) and answer with Allow, Deny, or Always allow where the agent offers it; a long command unfolds so you can read all of it. Under "Waiting for you" at the top of the conversation window's list you can allow or deny without opening the conversation at all.

What you can answer in Devalley differs by agent.

Agent In Devalley
Claude Code Allow, deny, always allow, and its multiple-choice questions
Codex, Qwen Code, OpenCode Allow, deny
Copilot CLI Allow, deny; not for sessions inside WSL
Antigravity CLI Approvals and questions in the conversation window; some sessions still have to be answered in their terminal
Hermes Once you turn it on in "Connect agents"
Gemini CLI No; the resident only shows that it is asking
Cursor, Amp No, and the resident doesn't show that they are waiting for approval

Devalley never allows a request for you. Nothing is allowed without your click, and a request you don't answer in the village can still be answered in its own terminal. It doesn't remove approvals; it makes keeping them on less of a chore. It can't be answered from a phone.

What are the same settings in Codex and Antigravity?

  • Codex: with approval_policy set to on-request, Codex runs commands the sandbox allows without asking and asks before actions outside it; with never (--ask-for-approval never) it doesn't ask. The sandbox is read-only, workspace-write or danger-full-access. --dangerously-bypass-approvals-and-sandbox (--yolo), which turns off both, is marked as not recommended (Codex approvals and security docs).
  • Antigravity CLI: --mode takes default, accept-edits, auto or plan, and Shift+Tab switches during a session. accept-edits approves file edits in your workspace automatically and still asks before terminal commands; auto needs the terminal sandbox and a personal account (Antigravity CLI docs).
  • Gemini CLI: --approval-mode takes default, auto_edit, yolo or plan.

The names differ and the idea is the same: there is a middle step that automates file edits only, and the switch that turns everything off carries a warning in every tool.

Frequently asked questions

How do you turn on an auto-approve mode in Claude Code?

Press Shift+Tab in a session to switch to acceptEdits, which approves file edits automatically, or start with claude --permission-mode acceptEdits. There is also auto mode, where a classifier reviews actions.

Is it all right to use --dangerously-skip-permissions?

The official docs say to use it only in isolated environments such as containers or VMs without internet access, because it offers no protection against prompt injection.

How do you stop Claude Code asking about the same command again and again?

Choose "Yes, and don't ask again" at the prompt, or add an allow rule such as Bash(npm run *) in /permissions.

How do you set auto-approve in Codex?

Set approval_policy to never, or run with --ask-for-approval never, and it stops asking. The sandbox setting stays separate.

Can approvals be less of a chore without turning them off?

Yes. Cut the number of prompts with allow rules, and answer the rest from one place with a notification hook, agent view, or an app such as Devalley that brings the request to your screen.

Download freeA free app for Windows and macOS. No account needed.