Claude Code memory (CLAUDE.md) configuration reference. Use when setting up project memory, understanding memory hierarchy, or configuring persistent instructions.
View on GitHubDuncanJurman/entropy-plugins
claude-code-docs
January 22, 2026
Select agents to install to:
npx add-skill https://github.com/DuncanJurman/entropy-plugins/blob/main/claude-code-docs/skills/memory-reference/SKILL.md -a claude-code --skill memory-referenceInstallation paths:
.claude/skills/memory-reference/# Claude Code Memory Reference Memory files (CLAUDE.md) provide persistent instructions that Claude loads every session. ## Memory Hierarchy (Priority Order) | Priority | Location | Purpose | Shared With | |----------|----------|---------|-------------| | 1 (highest) | Enterprise policy | Organization rules | All users | | 2 | `./CLAUDE.md` | Project instructions | Team via git | | 3 | `./.claude/CLAUDE.md` | Alternative project location | Team via git | | 4 | `./.claude/rules/*.md` | Modular project rules | Team via git | | 5 | `~/.claude/CLAUDE.md` | Personal preferences | Just you | | 6 | `./CLAUDE.local.md` | Personal project prefs | Just you (gitignored) | ## File Locations ``` /Library/Application Support/ClaudeCode/CLAUDE.md # Enterprise (macOS) ./CLAUDE.md # Project root ./.claude/CLAUDE.md # Alternative project ./.claude/rules/*.md # Modular rules ~/.claude/CLAUDE.md # User global ~/.claude/rules/*.md # User modular rules ./CLAUDE.local.md # Project personal ``` ## Basic CLAUDE.md ```markdown # Project Instructions ## Code Style - Use TypeScript for all new files - Prefer functional components in React - Use ESLint and Prettier for formatting ## Commands - Build: `npm run build` - Test: `npm test` - Lint: `npm run lint` ## Architecture - Components in `src/components/` - API routes in `src/api/` - Types in `src/types/` ``` ## Importing Files Use `@path/to/file` to import other files: ```markdown # Project Memory See @README.md for project overview. See @package.json for available commands. ## Team Guidelines @docs/guidelines.md ## Personal Preferences @~/.claude/my-prefs.md ``` Import rules: - Relative and absolute paths allowed - Max depth: 5 hops - Not evaluated in code blocks ## Modular Rules (.claude/rules/) Organize rules by topic: ```