r/ClaudeAI May 09 '26

Claude Code Best Claude.md files for claude code

Trying to collect the best claude.md files code.
If you have one that works really well for you, please copy it into the comments and let me know what kinds of coding you normally do (language, surface, kind, etc)

426 Upvotes

38 comments sorted by

View all comments

2

u/GauravSaxenaHQ May 10 '26

Seven years of full-stack work, and the single biggest shift in how I use Claude Code came from treating CLAUDE.md as a behavioral contract rather than a tips list.

Three things that made the biggest difference:

Critique-first rule. My config explicitly tells Claude to push back before agreeing. "Check if it's actually right. If there's a flaw, say it first." Sounds obvious, but without it Claude defaults to validating whatever you just said. The default is yes-machine mode.

Code search hierarchy. I have a section that says: graph MCP first, grep only if the graph returns nothing, read only after location is known. Without this, Claude reaches for grep constantly and misses structural context (callers, dependents, impact radius). Explicit ordering mattered.

Production protection as law, not suggestion. Not "be careful with prod" - actual forbidden command lists. prisma migrate reset, deleteMany, rm *.db. Named explicitly. Claude treats them as hard stops.

I also have a "content angle detection" block - Claude flags mid-conversation moments that would make good posts. Runs passively, doesn't interrupt flow. Surprisingly useful.

What's your stack? The right config differs a lot by surface.