Skip to main content
New to CLAUDE.md? — Start with the official CLAUDE.md guide for the basics. This page is the opinionated blueprint for making yours great.
CLAUDE.md is the highest-leverage configuration surface for Claude Code. It’s loaded into every conversation, so every line must earn its place. For how it fits into the broader instruction hierarchy alongside skills, agents, and hooks, see Context Distribution.

What CLAUDE.md Does

When you launch Claude Code in a directory, it walks the directory tree collecting CLAUDE.md files. More specific locations take precedence:

The 200-Line Budget

The system prompt already contains ~50 instructions. CLAUDE.md adds to that load. Frontier models follow approximately 150-200 instructions with reasonable consistency before quality degrades. Keep yours concise.

What Goes In (and What Doesn’t)

  • One-line project overview with tech stack
  • Build/test/lint commands (Claude uses these verbatim)
  • Brief architecture/directory map
  • Coding conventions Claude can’t infer from existing code
  • Critical warnings about gotchas
  • Pointers to detailed docs using @imports

The Pointer Pattern

CLAUDE.md points; it doesn’t explain. One line per concern — what to do and where to read more. Good:
Bad: A 30-line section explaining five auth rules with examples inline.

CLAUDE.md vs. Hooks

CLAUDE.md relies on LLM compliance — it’s advisory. For things that must always happen (formatting, linting, blocking .env commits), use hooks. Hooks execute as code.

Example

No frameworks, no tables of code patterns, no examples of implementation details. Those live in skills or reference docs.

Verifying Your Context

After editing CLAUDE.md, use the /context command inside Claude Code to see exactly what’s loaded into the conversation. This shows every CLAUDE.md file, @import, and skill that Claude can see — so you can confirm your changes landed and nothing is missing or duplicated.

Next Steps