Move Specialised CLAUDE.md Instructions into Skills to Shrink Context
Your CLAUDE.md file loads into context at the start of every session. If it's packed with detailed instructions for PR reviews, database migrations, and deployment checklists, all those tokens are present even when you're just fixing a typo.
Skills load on demand only when invoked, so moving workflow-specific instructions out of CLAUDE.md keeps your base context lean.
# Before: everything in CLAUDE.md (always loaded)
# CLAUDE.md = 800 lines of instructions
# After: essential rules in CLAUDE.md, workflows in skills
# CLAUDE.md = 200 lines of core project rules
# .claude/skills/pr-review/SKILL.md = PR review process
# .claude/skills/db-migration/SKILL.md = migration checklist
Keep CLAUDE.md under about 500 lines with just the essentials: coding standards, project structure, key conventions, and test commands. Move everything else into focused skills that Claude invokes when the task calls for them.
The token savings compound over a session. Every message Claude processes includes the system prompt, so a 600-line reduction in CLAUDE.md saves those tokens on every single API call.
A slim CLAUDE.md costs less on every message. Let skills carry the heavy instructions.
Log in to leave a comment.
Turn your most common prompts into reusable slash commands — drop a markdown file into .claude/commands/ and it becomes a /command you and your team can invoke anytime, with consistent instructions every time.
Create reusable slash commands in your project so common prompts like "run tests and fix failures" or "review this file for security issues" become a single /command instead of typing the same instructions every time.
The $ARGUMENTS placeholder in custom slash command files turns a static prompt into a reusable tool — pass different values each time you invoke it, just like a function that takes arguments.