claude-code - 💡(How to fix) Fix '/init' prompt shown even when .claude/CLAUDE.md exists [1 comments, 2 participants]

Official PRs (…)
ON THIS PAGE

Recommended Tools

×6

Utilities matched from this issue’s tags and category — try them while you read without losing context.

GitHub issue graph ai analysis

Paste a GitHub issue URL. We fetch that issue, discover linked issues from bodies/comments/timeline, collect linked pull requests, and produce a structured English report.

The report is written in English Markdown for sharing and archival.

Helpful · Quick feedback

Loading…
GitHub stats
anthropics/claude-code#45377Fetched 2026-04-09 08:06:50
View on GitHub
Comments
1
Participants
2
Timeline
5
Reactions
0
Timeline (top)
labeled ×4commented ×1

When starting a new session in a repo that has a .claude/CLAUDE.md file (but no root-level CLAUDE.md), Claude Code displays:

Run /init to create a CLAUDE.md file with instructions for Claude

This is misleading because .claude/CLAUDE.md is a supported and documented location — and it loads correctly. The startup check only looks for a root-level CLAUDE.md.

Root Cause

This is misleading because .claude/CLAUDE.md is a supported and documented location — and it loads correctly. The startup check only looks for a root-level CLAUDE.md.

RAW_BUFFERClick to expand / collapse

Description

When starting a new session in a repo that has a .claude/CLAUDE.md file (but no root-level CLAUDE.md), Claude Code displays:

Run /init to create a CLAUDE.md file with instructions for Claude

This is misleading because .claude/CLAUDE.md is a supported and documented location — and it loads correctly. The startup check only looks for a root-level CLAUDE.md.

Expected behavior

The /init prompt should not appear if .claude/CLAUDE.md exists, since that's a valid (and arguably preferred) location for project instructions.

Steps to reproduce

  1. Create a repo with instructions at .claude/CLAUDE.md (no root-level CLAUDE.md)
  2. Start a new Claude Code session in that repo
  3. Observe the /init prompt despite instructions loading correctly

Environment

  • Claude Code CLI
  • Linux (also likely reproducible on macOS)

extent analysis

TL;DR

Update the startup check in Claude Code to recognize .claude/CLAUDE.md as a valid location for project instructions.

Guidance

  • Verify that the .claude/CLAUDE.md file is correctly formatted and accessible.
  • Check the Claude Code documentation to see if there are any configuration options to specify the location of the CLAUDE.md file.
  • Modify the startup check to look for .claude/CLAUDE.md in addition to the root-level CLAUDE.md.
  • Test the updated startup check with a repository containing a .claude/CLAUDE.md file to ensure the /init prompt is not displayed.

Example

No code snippet is provided as the issue does not imply a specific code change, but rather a modification to the existing startup check logic.

Notes

The fix may require updates to the Claude Code CLI to recognize the .claude/CLAUDE.md location. This solution assumes that the .claude/CLAUDE.md file is a supported location for project instructions.

Recommendation

Apply a workaround by modifying the startup check to recognize .claude/CLAUDE.md as a valid location, as this is a documented and supported location for project instructions.

Vote matrix · Quick signals

Works
Did the solution work? Tap to confirm.
Easy Fix
Was it a quick fix?
Time Saver
Did it save you time?
Blocking
Was it severely blocking?
Common Issue
Are others likely hitting this too?
Flaky / Intermittent
Is it intermittent?
Verified / Reproducible
Can you reproduce it reliably?
Loading…

FAQ

Expected behavior

The /init prompt should not appear if .claude/CLAUDE.md exists, since that's a valid (and arguably preferred) location for project instructions.

Still need to ship something?

×6

Another batch ranked right after the header list — different links, same matching logic.

Back to top recommendations

TRENDING