
What Does /compact Do in Claude Code? (Context Management Explained)
The /compact command compresses your conversation history into a summary, freeing up tokens without losing context. Here's when and how to use it.
6 articles tagged with #slash-commands

The /compact command compresses your conversation history into a summary, freeing up tokens without losing context. Here's when and how to use it.
The /cost command shows your current session's token usage and estimated spend. Here's how to read it, what the numbers mean, and how to stay on budget.

The /init command scans your project and generates a CLAUDE.md file — a persistent briefing that tells Claude your conventions, stack, and rules. Here's how to use it.

The /model command lets you switch between Claude Opus, Sonnet, and Haiku mid-session. Here's when to use each model and how the opusplan mode works.

The /plan command puts Claude Code in read-only mode so it can analyze your codebase, ask questions, and create a detailed implementation plan before writing any code.

Complete reference guide to all Claude Code slash commands, CLI flags, keyboard shortcuts, and MCP integration with practical examples for developers.