Claude Code: Project Structure

πŸ“ŒOverview

The Claude Code Project Structure is a well-organized framework designed to streamline development workflows, ensure clarity in team collaboration, and maintain consistency across coding standards. It includes essential files, modular configurations, and automation hooks to optimize project management.

πŸ“ŒFile Descriptions

πŸ“ŒCore Files

CLAUDE.md

Loaded every single session. Contains project overview, tech stack, coding conventions, architecture notes, hard rules, and safety boundaries. Under 200 lines for clarity.

CLAUDE.local.md

Personal overrides. Never committed. Stores machine-specific paths, personal preferences, and experimental rules. Stacks on top of CLAUDE.md.

AGENTS.md

The team roster. Who does what. Defines subagent roles, capabilities, and handoff protocols. Prevents overlap and ensures multi-agent sessions stay coordinated.

mcp.json

MCP server integrations. Shared via git. Connects Claude to external services like GitHub, Notion, Slack, Gmail, PostgreSQL, and more.

πŸ“ŒConfiguration Files

settings.json

Permissions, tools, and hooks config. Defines what Claude can read, write, and execute. Includes allow/deny lists and hook events. Personal overrides go in settings.local.json.

rules/*.md

Modular rule files. Loaded on demand. Each .md file is a focused rule module (e.g., coding style, API conventions, testing standards). Keeps CLAUDE.md lean by externalizing details.

πŸ“ŒCommands and Skills

commands/*.md

Custom slash commands for your project. Each .md becomes a /project:command-name. Perfect for PR reviews, deploys, and scaffolding.

skills/<name>/SKILL.md

Auto-triggered by task context. Not a single fileβ€”organized by skill type. Loads only when Claude recognizes the task. Keeps runtime lightweight.

πŸ“ŒAgents and Hooks

agents/*.md

Specialized subagents with isolated context. Includes system prompts, own tools, and sandboxed execution windows for tasks like security reviews and research.

hooks/*.sh

Event-driven scripts. 100% enforcement. Automates Claude’s operations with deterministic shell commands. Includes pre/post hooks for validation and formatting.

πŸ“ŒMemory and Workflows

memory/*.md

Persistent memory across all sessions. Tracks project context, architectural decisions, and progress. Compensates for context resets.

workflows/*.md

Multi-step task blueprints. Defines repeatable workflows for feature builds, bug fixes, and code reviews. Combines skills, subagents, and hooks in sequence.

πŸ“ŒFlowchart

START
β†·
LOAD CLAUDE.md
β†·
APPLY LOCAL OVERRIDES
β†·
CONFIGURE AGENTS
β†·
CONNECT MCP
β†·
SET PERMISSIONS
β†·
LOAD RULES
β†·
EXECUTE COMMANDS
β†·
TRIGGER SKILLS
β†·
RUN AGENTS
β†·
ENFORCE HOOKS
β†·
TRACK MEMORY
β†·
FOLLOW WORKFLOWS
β†·
COMPLETE TASK

πŸ“ŒπŸ“– Real-Time Story

Imagine Sarah, a software engineer, working on a collaborative project using Claude Code.

Starting the Day: Sarah opens her project and loads CLAUDE.md, which provides her with an overview of the tech stack, coding conventions, and architecture notes. She reviews the hard rules to ensure compliance.
Personal Preferences: Her local machine automatically applies CLAUDE.local.md, customizing paths and preferences for her setup.
Team Coordination: Sarah checks AGENTS.md to confirm her role and responsibilities. She sees that her teammate Alex is handling security reviews, while she focuses on feature development.
Connecting Tools: The mcp.json file integrates Claude with GitHub and Slack, allowing Sarah to push updates and communicate seamlessly.
Executing Tasks: Sarah uses /project:deploy from commands/deploy.md to deploy the latest build. Claude automatically triggers relevant skills from skills/deploy/SKILL.md.
Validation and Automation: Before committing her code, pre-hooks from hooks/validate-code.sh ensure her changes meet coding standards.
Tracking Progress: Sarah updates memory/progress.md with notes on completed tasks, ensuring the team stays aligned.
Workflow Completion: Using workflows/feature-build.md, Sarah follows a multi-step blueprint to finalize the feature, combining subagents, hooks, and skills.

By the end of the day, Sarah has completed her tasks efficiently, leveraging the structured framework of Claude Code.