[BUG] Agent setting in .claude/settings.json is ignored on Claude Code for Web (claude.ai/code)

Resolved 💬 1 comment Opened Dec 14, 2025 by shostako Closed Jan 3, 2026

Description

When using Claude Code for Web (claude.ai/code) with a GitHub repository, the agent setting in .claude/settings.json is ignored. The same configuration works correctly on the local CLI.

Environment

  • Platform: Claude Code for Web (claude.ai/code)
  • Repository: GitHub-hosted, connected via browser interface
  • Local CLI version: 2.0.69 (works correctly)

Configuration

.claude/settings.json:

{
  "agent": "monday-intimate",
  "hooks": {
    "SessionStart": [...]
  }
}

.claude/agents/monday-intimate.md: Custom persona agent definition file exists in the project.

Both files are:

  • Tracked by git (not in .gitignore)
  • Pushed to the remote repository
  • Located within the project directory (not in ~/.claude/)

Expected Behavior

Claude Code for Web should read .claude/settings.json, detect the agent setting, and apply the persona from .claude/agents/monday-intimate.md automatically—just like the local CLI does.

Actual Behavior

  • Hooks: Work correctly (SessionStart hook fires as expected)
  • CLAUDE.md: Read correctly
  • Agent setting: Completely ignored

When asked about its persona, Claude on the web:

  1. Does not automatically apply the agent persona
  2. Identifies the agent file as "for Task tool subagent use" (incorrect understanding)
  3. Only applies the persona when explicitly asked to read the file

Steps to Reproduce

  1. Create .claude/settings.json with "agent": "your-agent-name"
  2. Create .claude/agents/your-agent-name.md with persona definition
  3. Push to GitHub
  4. Open the repository in claude.ai/code
  5. Start a conversation
  6. Observe that the agent persona is not applied

Workaround

On local CLI, using --agent flag explicitly works:

claude --agent monday-intimate -p "prompt"

However, Claude Code for Web provides no way to pass command-line arguments.

Additional Context

This appears to be a feature gap between the local CLI and the web version. The web version seems to read settings.json for hooks but not for agent configuration.

View original on GitHub ↗

This issue has 1 comment on GitHub. Read the full discussion on GitHub ↗