Omniscio

OmniscioGuidesDebug your configuration

Why Claude Code ignores your config: debug it

A setting you wrote, a hook you registered, a skill you added — and Claude behaves as if none of it exists. The usual cause is not a bug in Claude Code. The file did not load, it loaded from a different location than you thought, or another file quietly overrode it.

This page is the order to check them in: what loaded, what the resolved settings are, then each surface that can fail on its own — MCP servers, hooks, and the files that do not go where people put them.

Sources read on November 22, 2026. By the Omniscio team. Updated .

See what loaded into context

When Claude ignores an instruction, or a feature you configured does not appear, the cause is usually one of three: the file did not load, it loaded from a different location than you expected, or another file overrode it. The commands below show what Claude Code actually loaded, which narrows it to one.

/context shows everything occupying the context window for the current session, broken down by category: the system prompt, system tools, MCP tools, custom subagents with the source each loaded from, memory files, skills and conversation messages. Run it first, because it answers the basic question — is my CLAUDE.md, or my rule, or my skill's description, in there at all?

The skills section of /context also includes bundled skills, which /skills does not list.

In fullscreen mode, /context collapses the per-item breakdown. Run /context all to expand it.

For detail on one category, follow up with the dedicated command:

CommandShows
/memoryMemory file locations across user and project scopes, with the option to open each in your editor, plus the auto memory folder and toggle
/skillsAvailable skills from project, user and plugin sources
/hooksActive hook configurations
/mcpConnected MCP servers and their status
/permissionsResolved allow and deny rules currently in effect
/doctorA setup checkup: installation health, invalid settings files, unused extensions, duplicate subagent names in one directory, and CLAUDE.md content Claude can derive from the codebase, with proposed fixes
/debug [issue]Turns on debug logging for the session and prompts Claude to diagnose from the log output and settings paths
/statusActive settings sources, including whether managed settings are in effect

If a memory file is missing from the /context breakdown, check its location against how CLAUDE.md files load. Subdirectory CLAUDE.md files load on demand rather than at session start, so they do not appear in that breakdown even when they will load later.

If /context confirms the file loaded and Claude still does not follow one instruction, the problem is how the instruction is written rather than whether it loaded. Adherence drops when an instruction is vague enough to read two ways, when two files give conflicting direction, and when the file has grown long enough that individual rules get less attention.

One distinction is worth settling here: CLAUDE.md tells Claude how the project works so it makes good decisions, while permissions and hooks enforce limits whatever Claude decides. Anything that must never happen belongs in a permission rule or a hook, not in a paragraph of guidance.

Source: "See what loaded into context" in Debug your configuration, read November 22, 2026.

Check resolved settings

Settings merge across four scopes — managed, user, project and local. Managed settings apply first when present; among the rest, the closer scope overrides the broader one, in the order local, then project, then user. Command-line flags and environment variables are another override layer on top. When a setting does not seem to apply, the value you set is usually being overridden by another scope or by an environment variable.

Two commands separate the cases. claude doctor, run from your terminal, prints read-only installation and settings diagnostics without starting a session. /doctor, run inside a session, is a full checkup that also proposes fixes and asks before applying them. /status names the settings sources that are active, including whether managed settings are in effect. The /doctor guide covers what the checkup looks at, area by area.

Which file holds which key, and the order the files are read in, have their own guide: where settings.json lives. If the error is that Claude Code could not read a config file at all, the could-not-read-config guide covers that failure; this page covers the pile that loads without complaint and still does not take effect.

Source: "Check resolved settings" in Debug your configuration, read November 22, 2026.

MCP servers that do not appear

/mcp lists your servers and their connection status. A server can be defined correctly and still provide no tools, for a few documented reasons:

  • Approval was dismissed. Project-scoped servers in .mcp.json need a one-time approval. If you dismissed the prompt, the server stays disabled. Run claude mcp reset-project-choices and restart Claude Code, and it asks again for every project server.
  • A relative path. A server that fails to start shows as failed in /mcp, and relative file paths in command or args are a frequent cause: they resolve against the directory you launched Claude Code from, not the location of .mcp.json.
  • Connected, zero tools. A server that starts but returns no tool list shows as connected with nothing in it. Select Reconnect from /mcp; if the count stays at zero, run claude --debug=mcp and read the server's stderr in the debug log at ~/.claude/debug/<session-id>.txt. The debug logs guide covers the other flags and how to choose that file.

If the server is a project one, the guide to adding an MCP server covers the file and the approval prompt, and the MCP errors guide covers the messages a failed connection produces.

Source: "Check MCP servers" in Debug your configuration, read November 22, 2026.

Hooks that never fire

/hooks lists every hook registered for the current session, grouped by event. If a hook you defined is not in that list, Claude Code did not load it. Three causes are documented:

  • It is in a standalone file. Hooks go under the "hooks" key in a settings file; there is no separate hooks file for project or user configuration.
  • The matcher is an array. A matcher value that is a JSON array instead of a single string is listed as an invalid setting. If the array is under PreToolUse or PermissionRequest, none of that file's other hooks load either.
  • It belongs to a skill nobody has invoked. A hook in a skill's frontmatter loads only once you or Claude has invoked the skill in that session. Invoke it, then run /hooks again.

If the hook is listed but does not fire, the matcher is the usual cause. Use a single string with | to match several tools, as in "Edit|Write"; a comma is an equivalent separator now, but before v2.1.191 a comma fell through to regex evaluation and the matcher never matched. Matching is case-sensitive, so a lowercase "bash" matches nothing where Bash would. A misspelled tool name produces a matcher that matches nothing, and the hook fails silently.

You do not need to restart after editing settings.json: the change takes effect after a brief file-stability delay, even when the file or the .claude/ folder itself was created after the session started. Before v2.1.257 the folder case was not detected. If /hooks still shows the old definition a few seconds after you save, run it again to refresh the view.

If the hook shows and still does not fire, watch the evaluation live: start a session with claude --debug and trigger the tool call.

The hooks guide covers how a hook is written and which event to use, and the PreToolUse hook error guide covers a hook that runs and then blocks the tool.

Source: "Check hooks" in Debug your configuration, read November 22, 2026.

Test against a clean configuration

The fastest way to prove the cause is yours rather than Claude Code's is claude --safe-mode. It launches a session with your customizations disabled: CLAUDE.md; skills, plugins and hooks; MCP servers; custom commands and agents; custom output styles; and custom keybindings. Authentication, model selection, built-in tools and permissions work normally.

If the problem disappears in safe mode, the cause is one of the items it turned off, and each has its own check on this page. Safe mode still applies managed hooks and settings policy from your organization, though managed plugins, skills, CLAUDE.md and MCP servers are turned off.

If the problem survives safe mode, or you suspect the settings files themselves, start a session with none of your own configuration: create an empty directory, then launch with a fresh CLAUDE_CONFIG_DIR in place of ~/.claude and --setting-sources user to turn off project configuration.

mkdir -p ~/claude-clean/empty && cd ~/claude-clean/empty
CLAUDE_CONFIG_DIR=~/claude-clean/config claude --setting-sources user

On the first launch you go through the first-run setup screens again, which is the sign that the clean configuration directory is in effect. Managed settings still apply, and connectors still load if you sign in with a claude.ai account.

Then reproduce the problem. If it is gone, the cause is in your user or project configuration, so copy ~/.claude.json and the files in ~/.claude into the clean directory one at a time until it returns. If it persists, the cause is outside your user and project configuration: run /status to check for managed settings, check your shell for environment variables, and move on to Anthropic's troubleshooting page.

Source: "Test against a clean configuration" in Debug your configuration, read November 22, 2026.

The causes behind most surprises

Anthropic collects the location and syntax rules behind most configuration surprises in one table. These are the rows from it that this page covers:

What you seeWhyThe fix
A hook never firesThe matcher is a JSON array, not a stringUse one string with |, as in "Edit|Write"
A hook never firesThe matcher value is lowercaseMatching is case-sensitive: Bash, Edit, Write, Read
A hook never firesHooks are in a standalone filePut them under the "hooks" key in settings.json
Permissions or hooks set globally are ignoredThey were added to ~/.claude.jsonThat file holds app state; permissions, hooks and env belong in ~/.claude/settings.json
A settings.json value seems ignoredThe same key is set in settings.local.jsonsettings.local.json overrides settings.json, and both override the user file
A skill is missing from /skillsThe file is .claude/skills/name.mdUse a folder with SKILL.md inside: .claude/skills/name/SKILL.md
A skill is listed but Claude never uses itdisable-model-invocation: true, or a description that does not match how you askCheck the badge in /skills: "user-only" means Claude will not trigger it alone
A subdirectory CLAUDE.md seems ignoredSubdirectory files load on demand, not at session startAsk Claude to read another file in that subdirectory
A subagent ignores CLAUDE.mdThe built-in Explore and Plan agents skip it at startupRestate the instruction in your delegating prompt
A custom subagent ignores CLAUDE.mdIts definition sets omitClaudeMdRemove that field, or put the critical instructions in the agent file's body
MCP servers in .mcp.json never loadThe file is under .claude/, or its servers sit under a servers keyPut .mcp.json at the repository root with servers under mcpServers
MCP servers in settings.json never appearsettings.json does not read an mcpServers keyDefine them in .mcp.json, or use claude mcp add --scope user
An MCP server starts without its environment variablesThey are not in the environment Claude Code passes to stdio serversSet a per-server env inside that server's .mcp.json entry
A Bash(rm *) deny rule does not block /bin/rmBash rules match the literal command string, not the executableUse a PreToolUse hook or the sandbox for a hard guarantee

The settings.json location guide covers which file wins when a key is set in several places, and the CLAUDE.md guide covers where memory files load from.

Source: "Check common causes" and "Related resources" in Debug your configuration, read November 22, 2026.

Where these answers come from

No command on this page was run to check it: every symptom, cause and fix is Anthropic's own wording from the page above.

Common questions

Which command shows what Claude Code actually loaded?

Run /context. It breaks the context window down by category, including memory files, skills, MCP tools and custom subagents with the source each loaded from, so you can confirm whether your CLAUDE.md or a skill is present at all. In fullscreen mode run /context all to expand the per-item breakdown.

Why is my hook not firing even though it is in settings.json?

Check the matcher first. A JSON array instead of a single string is listed as an invalid setting, a lowercase tool name never matches because matching is case-sensitive, and a misspelled name matches nothing. Run /hooks to see whether the hook loaded at all.

I put permissions in ~/.claude.json and they are ignored. Why?

Because ~/.claude.json is a different file. It holds app state and UI toggles; permissions, hooks and env belong in ~/.claude/settings.json. That mix-up is one of the common causes Anthropic lists.

How do I prove the problem is my configuration and not Claude Code?

Start a session with claude --safe-mode, which turns off CLAUDE.md, skills, plugins, hooks, MCP servers, custom commands and agents, output styles and keybindings while authentication, model selection, built-in tools and permissions work normally. If the problem disappears, it is in one of those items.

Does a settings.json edit need a restart?

No. The change takes effect in the running session after a brief file-stability delay, even if you create the file or the .claude folder after the session started. If /hooks still shows the old definition a few seconds after saving, run it again to refresh the view.