Create custom subagents - Claude Code Docs

BlogJul 4, 2026

AI Summary

Official Claude Code documentation on subagents — specialized AI assistants that run in their own context window with their own system prompt, tool access, and permissions. Covers the built-in Explore/Plan/general-purpose agents, how to write and scope custom subagent files (.claude/agents/ vs ~/.claude/agents/), and common patterns like isolating high-volume operations and running parallel research.

Original excerpt

Subagents are specialized AI assistants that handle specific types of tasks. Use one when a side task would flood your main conversation with search results, logs, or file contents you won't reference again — the subagent does that work in its own context and returns only the summary. Define a custom subagent when you keep spawning the same kind of worker with the same instructions.

Each subagent runs in its own context window with a custom system prompt, specific tool access, and independent permissions. Subagents help you preserve context (keeping exploration and implementation out of the main conversation), enforce constraints (limiting which tools a subagent can use), reuse…

Frequently asked questions

What is "Create custom subagents - Claude Code Docs" about?

Official Claude Code documentation on subagents — specialized AI assistants that run in their own context window with their own system prompt, tool access, and permissions. Covers the built-in Explore/Plan/general-purpose agents, how to write and scope custom subagent files (.claude/agents/ vs ~/.cl…

Who wrote "Create custom subagents - Claude Code Docs"?

This piece is part of the Claude Code vault on Burn 451, covering agentic coding with claude. The original author is attributed at the source link.

How can I read more content from Claude Code?

The complete Claude Code reading list is available at burn451.cloud/vault/claude-code. Each article includes an AI-generated summary so you can decide what to read in seconds. Connect the Burn 451 MCP server to Claude or Cursor to query all Claude Code articles as live AI context.

Can I use "Create custom subagents - Claude Code Docs" with Claude or Cursor?

Yes. Install the burn-mcp-server npm package and connect it to Claude Desktop, Claude Code, or Cursor. Once connected, your AI can search and reference this article and the full Claude Code vault in real time — no manual copy-paste required.

12 more articles in this vault.

Import the full Claude Code vault to Burn 451 and build your own knowledge base.

Content attributed to the original author. Burn 451 curates publicly available writing as a reading index. For removal requests, contact @hawking520.