Solo Stack Kits Directory
Claude Code workflows & skills for solo consultants and freelancers

← Blog · 2026-10-17

Claude Code Keeps Asking for Permission? How to Stop the Prompts Safely

Shortcut: our free permissions builder writes the permissions block for settings.json, flags rules that won't do what you expect, and shows which rule decides a command you type. It runs in your browser.

Claude Code asks before it runs most shell commands, edits a file or fetches a web page. That is the Manual mode (default) working as designed. The prompts become a problem when you approve the same npm run test for the tenth time, or when "Yes, and don't ask again" doesn't seem to stick.

You have three levers: permission rules (allow, ask, deny), the permission mode a session starts in, and where the rules are saved. Here is how to use them without handing Claude a blank check.

1. Know what asks and what doesn't

From Anthropic's permissions docs:

2. Why "don't ask again" didn't stick

3. Write allow rules for the commands you trust

Add rules to settings.json under permissions.allow. Write the command, and replace the parts that change with *:

{
  "permissions": {
    "allow": [
      "Bash(npm run *)",
      "Bash(git add *)",
      "Bash(git commit *)"
    ],
    "ask": [
      "Bash(git push *)"
    ],
    "deny": [
      "Read(./.env)",
      "Read(./.env.*)",
      "Read(./secrets/**)"
    ]
  }
}

Four rules of thumb from the docs:

  1. Put the * after the subcommand. Bash(git commit *) allows commits. Bash(git *) allows every git command, including git push and git -c ..., which can run a program you name.
  2. Mind the space. Bash(ls *) matches ls and ls -la but not lsof. Bash(ls*) matches all three.
  3. Deny beats ask beats allow. Claude Code checks deny rules first, then ask, then allow, and the first match wins. A narrow allow can't carve an exception out of a broad deny.
  4. Allow has to match every part of a compound command; deny and ask only have to match one part.

Not sure what a rule will catch? Paste it into the permissions builder and type a command into its tester.

4. Pick a mode instead of approving edits one by one

Set defaultMode in permissions, or switch during a session:

5. Save rules in the right file

If a rule exists at any level as a deny, no other level can allow it.

6. Things rules can't do


Rules spread across user, project and local files? The free settings precedence checker merges them and flags allow rules that an ask or deny rule cancels. For settings that seem ignored altogether, see Claude Code settings not applying? 12 causes and fixes.

Facts on this page come from Anthropic's permissions documentation. This guide isn't affiliated with Anthropic.

If you use Claude Code for client work, skills handle the repeat jobs so you spend less time steering. Start with our free 3-skill sample (client follow-ups, meeting notes to tasks, invoice chasing), or get the full Solo Consultant Kit.