Skip to content
BENIBIX Learn

defaultShell

AI⌨️ Claude CodeConfiguration

Also known as defaultShell setting

The key that picks Bash or PowerShell for your ! commands.

Think of it like

It is like telling the desk clerk which tongue you speak.

Example

Lucy works on Windows and knows PowerShell well. She sets defaultShell to powershell for her ! commands.

Why it matters

A command written for one shell often fails in the other.

Definition

defaultShell is a settings key that picks which shell runs the commands you type after ! in the input box. The values are bash and powershell. The default is bash, or powershell on Windows when Bash is not there. If the shell you name is not there, Claude Code uses the other one.

Example code

json
{
  "defaultShell": "powershell"
}
Run your ! commands in PowerShell.

Common mistake

Thinking it changes the shell Claude uses for its own tool calls. It is only for the commands you type after !.

Key takeaways

  1. 1
    Your ! commands. Not Claude's.
  2. 2
    bash or powershell. Two values.
  3. 3
    Falls back. If missing.