[{"data":1,"prerenderedAt":56},["ShallowReactive",2],{"blog-claude-code-permission-modes":3,"blog-related-claude-code-permission-modes":39},{"slug":4,"title":5,"description":6,"category":7,"categoryId":8,"keyword":9,"date":10,"minutes":11,"body":12,"html":13,"headings":14},"claude-code-permission-modes","Claude Code permission modes explained (and when to use each)","Default, acceptEdits, plan, auto, dontAsk and bypassPermissions: what each Claude Code permission mode allows, how to switch, and which one fits which job.","Getting started","getting-started","claude code permission modes","2026-11-17",5,"A Claude Code permission mode decides which actions run without asking you. Press `Shift+Tab` to cycle through them in a session, or start with `claude --permission-mode \u003Cmode>`. There are six: `default`, `acceptEdits`, `plan`, `auto`, `dontAsk` and `bypassPermissions`. Picking the right one is the difference between approving forty prompts a day and trusting something you should have read.\n\n## What are the six permission modes?\n\n| Mode | Runs without asking | Good for |\n| --- | --- | --- |\n| `default` (alias `manual` on the command line) | Reads only | Reviewing every action yourself |\n| `acceptEdits` | Reads, file edits, and common filesystem commands (`mkdir`, `touch`, `mv`, `cp`, `sed`, `rm`, `rmdir`) inside the working directory | Iterating on code you will review afterwards |\n| `plan` | Reads; edits stay blocked until you approve a plan | Exploring before changing anything |\n| `auto` | Everything, while a classifier model reviews actions in the background | Long tasks, fewer prompts |\n| `dontAsk` | File reads in working directories and pre-approved tools; anything that would prompt is denied | Locked-down scripts and CI |\n| `bypassPermissions` | Everything | Isolated containers and VMs only |\n\nTwo details are easy to miss. In `acceptEdits`, other shell commands still prompt, and so does anything outside the working directory (and the folders you added). And protected paths such as `.git`, `.claude`, shell rc files and `.mcp.json` prompt in `default` and `acceptEdits` rather than going through.\n\n## How do you switch modes?\n\n**In a session**, press `Shift+Tab`. The status bar shows where you are: `⏸ manual mode on`, `⏵⏵ accept edits on`, `⏸ plan mode on`, `⏵⏵ auto mode on`. The cycle runs `default`, `acceptEdits`, `plan`, with optional modes after. `auto` appears when it is available to you; `bypassPermissions` appears only if you enabled it at startup; `dontAsk` never appears in the cycle.\n\n**At startup:**\n\n```sh\nclaude --permission-mode plan\nclaude --permission-mode acceptEdits\nclaude --permission-mode dontAsk\n```\n\n**As a default**, in a settings file:\n\n```json\n{\n  \"permissions\": {\n    \"defaultMode\": \"acceptEdits\"\n  }\n}\n```\n\nSettings precedence applies when several files set it. Note that `auto` and `bypassPermissions` set in a project's `.claude\u002Fsettings.json` or `.claude\u002Fsettings.local.json` have no effect: those belong in your user settings (`~\u002F.claude\u002Fsettings.json`) or in managed settings. That is deliberate, so a repository you clone cannot switch your safety off.\n\n## When should you use acceptEdits or plan?\n\nUse `acceptEdits` when you will review the result as a diff anyway. Refactors, test writing, renames and boilerplate are the classic cases: each edit is cheap to inspect afterwards, and approving them one by one is noise. Combine it with a clean git state so `git diff` shows exactly what changed. It does not cover arbitrary shell commands, so a `curl | sh` or a `git push` still asks.\n\nUse `plan` before anything that touches several files or that you do not understand yet. Claude reads and explores, writes a plan, and cannot edit source until you approve it. It has its own article: [plan mode in Claude Code](\u002Fblog\u002Fclaude-code-plan-mode).\n\n## What does auto mode do, and is it safe?\n\nIn auto mode a separate classifier model reviews each action before it runs. It blocks actions that go beyond what you asked, that target infrastructure it does not recognize, or that look driven by hostile content Claude read (a prompt injection in a web page, say). Entering it drops broad allow rules such as `Bash(*)` or wildcarded interpreters, and restores them when you leave; narrow rules like `Bash(npm test)` stay. Three consecutive blocks or twenty in total pause it and bring the prompts back.\n\nAvailability depends on your plan, your model and your Claude Code version, and administrators can disable it, so check `Shift+Tab` on your machine. The docs are clear that it reduces prompts but is not a guarantee: use it where you trust the general direction of the task, not for sensitive operations.\n\n## When is dontAsk the right choice?\n\nFor non-interactive runs where a prompt would hang or be meaningless. It denies everything that is not pre-approved, so you pair it with an explicit allowlist:\n\n```sh\nclaude -p \"run the test suite\" \\\n  --permission-mode dontAsk \\\n  --allowedTools \"Bash(npm test)\" \"Read\"\n```\n\nIf the job tries something outside the list, it fails instead of waiting for an answer nobody will give. See headless mode and CI in the usual docs; it is the right default for anything unattended.\n\n## Is bypassPermissions ever okay?\n\nOnly in an environment that is already disposable: a container, a VM, a dev container without internet access. The docs say it offers no protection against prompt injection or unintended actions. Know what it still does and does not do:\n\n- Deny rules still block; allow rules have no effect.\n- Explicit `ask` rules, and some critical-path `rm` removals, still prompt.\n- Protected paths like `.git` and `.claude` become writable.\n- You cannot switch to it mid-session; it has to be enabled at launch with `--permission-mode bypassPermissions` or `--dangerously-skip-permissions`.\n- On Linux and macOS it refuses to start as root or under `sudo` unless it detects a sandbox.\n\nIf you run it on your laptop with your real credentials in reach, you are one bad web page away from a bad day.\n\n## A practical way to choose\n\n1. New to the codebase or the tool: `default`, read what you approve. ([Beginner's guide](\u002Fblog\u002Fclaude-code-beginners-guide).)\n2. Unclear task: `plan` first, then switch.\n3. Well-understood edit, you will review the diff: `acceptEdits`.\n4. Long task in a repo you trust: `auto`, if you have it.\n5. Scripts and CI: `dontAsk` with an allowlist.\n6. Throwaway sandbox: `bypassPermissions`.\n\nFor rules that must always hold, whatever the mode, use `permissions.deny` in settings, or a hook; instructions in [CLAUDE.md](\u002Fblog\u002Fclaude-md-guide) are guidance, not a lock.\n\n## In Relais\n\nRelais has a permission-mode picker in each session's composer with four choices: Ask, Accept edits, Plan and Full access, which map to `default`, `acceptEdits`, `plan` and `bypassPermissions`. Edits arrive as inline approval cards with their diff, and you can hide the picker in Settings if you always use the same mode. Session templates can also set the mode a session starts with. See [features](\u002Ffeatures).","\u003Cp>A Claude Code permission mode decides which actions run without asking you. Press \u003Ccode>Shift+Tab\u003C\u002Fcode> to cycle through them in a session, or start with \u003Ccode>claude --permission-mode &lt;mode&gt;\u003C\u002Fcode>. There are six: \u003Ccode>default\u003C\u002Fcode>, \u003Ccode>acceptEdits\u003C\u002Fcode>, \u003Ccode>plan\u003C\u002Fcode>, \u003Ccode>auto\u003C\u002Fcode>, \u003Ccode>dontAsk\u003C\u002Fcode> and \u003Ccode>bypassPermissions\u003C\u002Fcode>. Picking the right one is the difference between approving forty prompts a day and trusting something you should have read.\u003C\u002Fp>\n\u003Ch2 id=\"what-are-the-six-permission-modes\">\u003Ca class=\"anchor\" href=\"#what-are-the-six-permission-modes\" aria-label=\"Link to this section\">#\u003C\u002Fa>What are the six permission modes?\u003C\u002Fh2>\n\u003Cdiv class=\"table-wrap\">\u003Ctable>\u003Cthead>\u003Ctr>\u003Cth>Mode\u003C\u002Fth>\u003Cth>Runs without asking\u003C\u002Fth>\u003Cth>Good for\u003C\u002Fth>\u003C\u002Ftr>\u003C\u002Fthead>\u003Ctbody>\u003Ctr>\u003Ctd>\u003Ccode>default\u003C\u002Fcode> (alias \u003Ccode>manual\u003C\u002Fcode> on the command line)\u003C\u002Ftd>\u003Ctd>Reads only\u003C\u002Ftd>\u003Ctd>Reviewing every action yourself\u003C\u002Ftd>\u003C\u002Ftr>\u003Ctr>\u003Ctd>\u003Ccode>acceptEdits\u003C\u002Fcode>\u003C\u002Ftd>\u003Ctd>Reads, file edits, and common filesystem commands (\u003Ccode>mkdir\u003C\u002Fcode>, \u003Ccode>touch\u003C\u002Fcode>, \u003Ccode>mv\u003C\u002Fcode>, \u003Ccode>cp\u003C\u002Fcode>, \u003Ccode>sed\u003C\u002Fcode>, \u003Ccode>rm\u003C\u002Fcode>, \u003Ccode>rmdir\u003C\u002Fcode>) inside the working directory\u003C\u002Ftd>\u003Ctd>Iterating on code you will review afterwards\u003C\u002Ftd>\u003C\u002Ftr>\u003Ctr>\u003Ctd>\u003Ccode>plan\u003C\u002Fcode>\u003C\u002Ftd>\u003Ctd>Reads; edits stay blocked until you approve a plan\u003C\u002Ftd>\u003Ctd>Exploring before changing anything\u003C\u002Ftd>\u003C\u002Ftr>\u003Ctr>\u003Ctd>\u003Ccode>auto\u003C\u002Fcode>\u003C\u002Ftd>\u003Ctd>Everything, while a classifier model reviews actions in the background\u003C\u002Ftd>\u003Ctd>Long tasks, fewer prompts\u003C\u002Ftd>\u003C\u002Ftr>\u003Ctr>\u003Ctd>\u003Ccode>dontAsk\u003C\u002Fcode>\u003C\u002Ftd>\u003Ctd>File reads in working directories and pre-approved tools; anything that would prompt is denied\u003C\u002Ftd>\u003Ctd>Locked-down scripts and CI\u003C\u002Ftd>\u003C\u002Ftr>\u003Ctr>\u003Ctd>\u003Ccode>bypassPermissions\u003C\u002Fcode>\u003C\u002Ftd>\u003Ctd>Everything\u003C\u002Ftd>\u003Ctd>Isolated containers and VMs only\u003C\u002Ftd>\u003C\u002Ftr>\u003C\u002Ftbody>\u003C\u002Ftable>\u003C\u002Fdiv>\n\u003Cp>Two details are easy to miss. In \u003Ccode>acceptEdits\u003C\u002Fcode>, other shell commands still prompt, and so does anything outside the working directory (and the folders you added). And protected paths such as \u003Ccode>.git\u003C\u002Fcode>, \u003Ccode>.claude\u003C\u002Fcode>, shell rc files and \u003Ccode>.mcp.json\u003C\u002Fcode> prompt in \u003Ccode>default\u003C\u002Fcode> and \u003Ccode>acceptEdits\u003C\u002Fcode> rather than going through.\u003C\u002Fp>\n\u003Ch2 id=\"how-do-you-switch-modes\">\u003Ca class=\"anchor\" href=\"#how-do-you-switch-modes\" aria-label=\"Link to this section\">#\u003C\u002Fa>How do you switch modes?\u003C\u002Fh2>\n\u003Cp>\u003Cstrong>In a session\u003C\u002Fstrong>, press \u003Ccode>Shift+Tab\u003C\u002Fcode>. The status bar shows where you are: \u003Ccode>⏸ manual mode on\u003C\u002Fcode>, \u003Ccode>⏵⏵ accept edits on\u003C\u002Fcode>, \u003Ccode>⏸ plan mode on\u003C\u002Fcode>, \u003Ccode>⏵⏵ auto mode on\u003C\u002Fcode>. The cycle runs \u003Ccode>default\u003C\u002Fcode>, \u003Ccode>acceptEdits\u003C\u002Fcode>, \u003Ccode>plan\u003C\u002Fcode>, with optional modes after. \u003Ccode>auto\u003C\u002Fcode> appears when it is available to you; \u003Ccode>bypassPermissions\u003C\u002Fcode> appears only if you enabled it at startup; \u003Ccode>dontAsk\u003C\u002Fcode> never appears in the cycle.\u003C\u002Fp>\n\u003Cp>\u003Cstrong>At startup:\u003C\u002Fstrong>\u003C\u002Fp>\n\u003Cpre class=\"code\" data-lang=\"sh\">\u003Ccode>claude --permission-mode plan\nclaude --permission-mode acceptEdits\nclaude --permission-mode dontAsk\u003C\u002Fcode>\u003C\u002Fpre>\n\u003Cp>\u003Cstrong>As a default\u003C\u002Fstrong>, in a settings file:\u003C\u002Fp>\n\u003Cpre class=\"code\" data-lang=\"json\">\u003Ccode>{\n  \u003Cspan class=\"hljs-string\">\"permissions\"\u003C\u002Fspan>: {\n    \u003Cspan class=\"hljs-string\">\"defaultMode\"\u003C\u002Fspan>: \u003Cspan class=\"hljs-string\">\"acceptEdits\"\u003C\u002Fspan>\n  }\n}\u003C\u002Fcode>\u003C\u002Fpre>\n\u003Cp>Settings precedence applies when several files set it. Note that \u003Ccode>auto\u003C\u002Fcode> and \u003Ccode>bypassPermissions\u003C\u002Fcode> set in a project&#39;s \u003Ccode>.claude\u002Fsettings.json\u003C\u002Fcode> or \u003Ccode>.claude\u002Fsettings.local.json\u003C\u002Fcode> have no effect: those belong in your user settings (\u003Ccode>~\u002F.claude\u002Fsettings.json\u003C\u002Fcode>) or in managed settings. That is deliberate, so a repository you clone cannot switch your safety off.\u003C\u002Fp>\n\u003Ch2 id=\"when-should-you-use-acceptedits-or-plan\">\u003Ca class=\"anchor\" href=\"#when-should-you-use-acceptedits-or-plan\" aria-label=\"Link to this section\">#\u003C\u002Fa>When should you use acceptEdits or plan?\u003C\u002Fh2>\n\u003Cp>Use \u003Ccode>acceptEdits\u003C\u002Fcode> when you will review the result as a diff anyway. Refactors, test writing, renames and boilerplate are the classic cases: each edit is cheap to inspect afterwards, and approving them one by one is noise. Combine it with a clean git state so \u003Ccode>git diff\u003C\u002Fcode> shows exactly what changed. It does not cover arbitrary shell commands, so a \u003Ccode>curl | sh\u003C\u002Fcode> or a \u003Ccode>git push\u003C\u002Fcode> still asks.\u003C\u002Fp>\n\u003Cp>Use \u003Ccode>plan\u003C\u002Fcode> before anything that touches several files or that you do not understand yet. Claude reads and explores, writes a plan, and cannot edit source until you approve it. It has its own article: \u003Ca href=\"\u002Fblog\u002Fclaude-code-plan-mode\">plan mode in Claude Code\u003C\u002Fa>.\u003C\u002Fp>\n\u003Ch2 id=\"what-does-auto-mode-do-and-is-it-safe\">\u003Ca class=\"anchor\" href=\"#what-does-auto-mode-do-and-is-it-safe\" aria-label=\"Link to this section\">#\u003C\u002Fa>What does auto mode do, and is it safe?\u003C\u002Fh2>\n\u003Cp>In auto mode a separate classifier model reviews each action before it runs. It blocks actions that go beyond what you asked, that target infrastructure it does not recognize, or that look driven by hostile content Claude read (a prompt injection in a web page, say). Entering it drops broad allow rules such as \u003Ccode>Bash(*)\u003C\u002Fcode> or wildcarded interpreters, and restores them when you leave; narrow rules like \u003Ccode>Bash(npm test)\u003C\u002Fcode> stay. Three consecutive blocks or twenty in total pause it and bring the prompts back.\u003C\u002Fp>\n\u003Cp>Availability depends on your plan, your model and your Claude Code version, and administrators can disable it, so check \u003Ccode>Shift+Tab\u003C\u002Fcode> on your machine. The docs are clear that it reduces prompts but is not a guarantee: use it where you trust the general direction of the task, not for sensitive operations.\u003C\u002Fp>\n\u003Ch2 id=\"when-is-dontask-the-right-choice\">\u003Ca class=\"anchor\" href=\"#when-is-dontask-the-right-choice\" aria-label=\"Link to this section\">#\u003C\u002Fa>When is dontAsk the right choice?\u003C\u002Fh2>\n\u003Cp>For non-interactive runs where a prompt would hang or be meaningless. It denies everything that is not pre-approved, so you pair it with an explicit allowlist:\u003C\u002Fp>\n\u003Cpre class=\"code\" data-lang=\"sh\">\u003Ccode>claude -p &quot;run the test suite&quot; \\\n  --permission-mode dontAsk \\\n  --allowedTools &quot;Bash(npm test)&quot; &quot;Read&quot;\u003C\u002Fcode>\u003C\u002Fpre>\n\u003Cp>If the job tries something outside the list, it fails instead of waiting for an answer nobody will give. See headless mode and CI in the usual docs; it is the right default for anything unattended.\u003C\u002Fp>\n\u003Ch2 id=\"is-bypasspermissions-ever-okay\">\u003Ca class=\"anchor\" href=\"#is-bypasspermissions-ever-okay\" aria-label=\"Link to this section\">#\u003C\u002Fa>Is bypassPermissions ever okay?\u003C\u002Fh2>\n\u003Cp>Only in an environment that is already disposable: a container, a VM, a dev container without internet access. The docs say it offers no protection against prompt injection or unintended actions. Know what it still does and does not do:\u003C\u002Fp>\n\u003Cul>\n\u003Cli>Deny rules still block; allow rules have no effect.\u003C\u002Fli>\n\u003Cli>Explicit \u003Ccode>ask\u003C\u002Fcode> rules, and some critical-path \u003Ccode>rm\u003C\u002Fcode> removals, still prompt.\u003C\u002Fli>\n\u003Cli>Protected paths like \u003Ccode>.git\u003C\u002Fcode> and \u003Ccode>.claude\u003C\u002Fcode> become writable.\u003C\u002Fli>\n\u003Cli>You cannot switch to it mid-session; it has to be enabled at launch with \u003Ccode>--permission-mode bypassPermissions\u003C\u002Fcode> or \u003Ccode>--dangerously-skip-permissions\u003C\u002Fcode>.\u003C\u002Fli>\n\u003Cli>On Linux and macOS it refuses to start as root or under \u003Ccode>sudo\u003C\u002Fcode> unless it detects a sandbox.\u003C\u002Fli>\n\u003C\u002Ful>\n\u003Cp>If you run it on your laptop with your real credentials in reach, you are one bad web page away from a bad day.\u003C\u002Fp>\n\u003Ch2 id=\"a-practical-way-to-choose\">\u003Ca class=\"anchor\" href=\"#a-practical-way-to-choose\" aria-label=\"Link to this section\">#\u003C\u002Fa>A practical way to choose\u003C\u002Fh2>\n\u003Col>\n\u003Cli>New to the codebase or the tool: \u003Ccode>default\u003C\u002Fcode>, read what you approve. (\u003Ca href=\"\u002Fblog\u002Fclaude-code-beginners-guide\">Beginner&#39;s guide\u003C\u002Fa>.)\u003C\u002Fli>\n\u003Cli>Unclear task: \u003Ccode>plan\u003C\u002Fcode> first, then switch.\u003C\u002Fli>\n\u003Cli>Well-understood edit, you will review the diff: \u003Ccode>acceptEdits\u003C\u002Fcode>.\u003C\u002Fli>\n\u003Cli>Long task in a repo you trust: \u003Ccode>auto\u003C\u002Fcode>, if you have it.\u003C\u002Fli>\n\u003Cli>Scripts and CI: \u003Ccode>dontAsk\u003C\u002Fcode> with an allowlist.\u003C\u002Fli>\n\u003Cli>Throwaway sandbox: \u003Ccode>bypassPermissions\u003C\u002Fcode>.\u003C\u002Fli>\n\u003C\u002Fol>\n\u003Cp>For rules that must always hold, whatever the mode, use \u003Ccode>permissions.deny\u003C\u002Fcode> in settings, or a hook; instructions in \u003Ca href=\"\u002Fblog\u002Fclaude-md-guide\">CLAUDE.md\u003C\u002Fa> are guidance, not a lock.\u003C\u002Fp>\n\u003Ch2 id=\"in-relais\">\u003Ca class=\"anchor\" href=\"#in-relais\" aria-label=\"Link to this section\">#\u003C\u002Fa>In Relais\u003C\u002Fh2>\n\u003Cp>Relais has a permission-mode picker in each session&#39;s composer with four choices: Ask, Accept edits, Plan and Full access, which map to \u003Ccode>default\u003C\u002Fcode>, \u003Ccode>acceptEdits\u003C\u002Fcode>, \u003Ccode>plan\u003C\u002Fcode> and \u003Ccode>bypassPermissions\u003C\u002Fcode>. Edits arrive as inline approval cards with their diff, and you can hide the picker in Settings if you always use the same mode. Session templates can also set the mode a session starts with. See \u003Ca href=\"\u002Ffeatures\">features\u003C\u002Fa>.\u003C\u002Fp>\n",[15,18,21,24,27,30,33,36],{"id":16,"text":17},"what-are-the-six-permission-modes","What are the six permission modes?",{"id":19,"text":20},"how-do-you-switch-modes","How do you switch modes?",{"id":22,"text":23},"when-should-you-use-acceptedits-or-plan","When should you use acceptEdits or plan?",{"id":25,"text":26},"what-does-auto-mode-do-and-is-it-safe","What does auto mode do, and is it safe?",{"id":28,"text":29},"when-is-dontask-the-right-choice","When is dontAsk the right choice?",{"id":31,"text":32},"is-bypasspermissions-ever-okay","Is bypassPermissions ever okay?",{"id":34,"text":35},"a-practical-way-to-choose","A practical way to choose",{"id":37,"text":38},"in-relais","In Relais",[40,45,51],{"slug":41,"title":42,"description":43,"category":7,"categoryId":8,"keyword":44,"date":10,"minutes":11},"claude-code-beginners-guide","Claude Code for beginners: install, first session, habits","Install Claude Code, run your first session and learn the habits that matter: specific prompts, plan before edit, CLAUDE.md, small commits, a clean context.","claude code for beginners",{"slug":46,"title":47,"description":48,"category":7,"categoryId":8,"keyword":49,"date":10,"minutes":50},"claude-code-hooks","Claude Code hooks: run a script on every tool call","Claude Code hooks run your own script before or after a tool call. Learn the config format, exit codes and three working examples you can paste today.","claude code hooks",6,{"slug":52,"title":53,"description":54,"category":7,"categoryId":8,"keyword":55,"date":10,"minutes":11},"claude-code-skills","Claude Code skills: what they are and how to write one","A Claude Code skill is a folder with a SKILL.md that Claude loads when relevant or you call with a slash. See the format, frontmatter fields and an example.","claude code skills",1794931098788]