/config slash command (aliased as /settings) opens an interactive settings panel inside a running Claude Code session. It is not a standalone CLI subcommand with get / set subcommands — configuration is managed through the panel UI or by editing the settings JSON files directly.
Settings files
Claude Code merges settings from multiple sources in order of precedence (highest to lowest):| Source | Location | Scope |
|---|---|---|
CLI --settings flag | Path or inline JSON | Session only |
| Local settings | .claude/settings.local.json | Project, not committed |
| Project settings | .claude/settings.json | Project, committed |
| User settings | ~/.claude/settings.json | All projects |
| Managed settings | System-level path | Enterprise-managed |
Key settings fields
The settings files follow a JSON schema. Common fields include:Override the default model used by Claude Code. Accepts a model alias (e.g.
"sonnet") or a full model ID (e.g. "claude-sonnet-4-6").Default permission mode. Choices:
default, acceptEdits,
bypassPermissions, dontAsk, plan.List of permission rules for allowed operations (e.g.
["Bash(git:*)"]).List of permission rules for denied operations.
Environment variables to set for Claude Code sessions (key-value string
pairs).
Custom commands to run before or after tool executions. See the hooks
documentation for the full schema.
Number of days to retain chat transcripts (default: 30). Set to
0 to
disable session persistence entirely — no transcripts are written and existing
ones are deleted at startup.Deprecated. Use
attribution instead. Whether to include Claude’s
co-authored-by attribution in commits and pull requests (defaults to true).Attribution text appended to git commits. Set to an empty string to hide
attribution.
Attribution text appended to pull request descriptions. Set to an empty
string to hide attribution.
Whether the file picker should respect
.gitignore files (default: true).
Note: .ignore files are always respected.Default shell for input-box
! commands. Choices: bash, powershell.
Defaults to bash on all platforms.Disable all hooks and the status line execution.
Example settings file
~/.claude/settings.json
Use the
--setting-sources flag at startup to control which sources are
loaded: claude --setting-sources user,project.