Bible Network Crypto DeFi Onchain RWA AI Agent Stablecoin Chain SAFU CryptoTax DeFAI AGI Claude Me Claude Skill Claude Design Claude Cowork
Independent Media
Not affiliated with any project
Learn Claude Skills. Do Everything Better.
claudeskill-me.com
LATEST
Your Hook Says "Blocking Error" But the File Still Changed? PostToolUse and PreToolUse Don't Actually Block the Same Way  ·  Enabled Auto Mode and Thought You Were Safe? Permission Modes and Sandbox Boundaries Are Two Different Layers — Conflating Them Is How Things Break  ·  Messages API Adds On-Demand Compaction in Beta: Developers Decide When to Compact, Not the System  ·  Claude Cowork and Chat Officially Merge, Launching Claude Docs and Claude Slides Alongside It  ·  Why a Single "hi" Can Burn 20,000+ Tokens in Claude Code: Breaking Down the Fixed Startup Overhead  ·  How to Write Your First Custom Slash Command in Claude Code: A Working Example From Scratch
Glossary · Workflow

Subagent

Workflow intermediate

30-Second Version · For the impatient
A separate Claude instance the main session spawns to handle one specific job, with its own Context Window and tool permissions, reporting back only the final result rather than flooding the main conversation with every intermediate step.
Full Explanation +
01 · What is this?

What is a Subagent, and how does it differ from the main conversation handling a task directly?

A subagent is a separate, independently operating Claude instance that the main session spawns — it has its own System Prompt, its own tool list, and can even run on a different model than the main conversation. The main conversation only sees the subagent's final summary report; it never sees which files it read or what steps it tried along the way — that process is isolated inside the subagent's own Context Window and doesn't consume space in the main conversation.

The key difference from handling a task directly in the main conversation is context isolation. If a task runs directly in the main conversation, every step of the process (reading files, analyzing, fixing) stays fully in the conversation history, and over time this fills up the context. A subagent isolates that process, keeping the main conversation clean enough to support longer, multi-turn discussion without being drowned out by the execution details of a single task.

02 · Why does it exist?

Why is a Subagent needed, and what problem does it solve?

Before subagents existed, complex tasks (reviewing a large PR, or a refactor requiring multiple steps) running directly in the main conversation created two concrete problems. First, as mentioned above, the context gets flooded with process detail. Second, tasks interfere with each other — trying to advance several unrelated pieces of work in the same conversation easily disrupts each other's thread, forcing the user to keep reminding Claude to "go back to what we were doing."

A subagent gives each task its own clean context space to run in, without interfering with anything else; background subagents go a step further, letting a subagent run concurrently alongside the main conversation so the user doesn't have to stop and wait for a task to finish. This shifts how Claude handles complex, multi-task workflows from "focus on one thing at a time" to "decompose work into parallel, isolated tracks that each move forward independently."

03 · How does it affect your decisions?

How does a Subagent actually work, and what execution modes does it support?

The most basic way to define a subagent is to place a Markdown file under .claude/agents/, using frontmatter to define its name, description, available tools, and model, with the body serving as that subagent's System Prompt. The main conversation (the lead agent) reads each defined subagent's description text and judges whether the current task is a good fit to hand off — a judgment process similar to how Claude decides whether to call a particular tool.

Execution splits into two modes: foreground and background. A foreground subagent blocks the main conversation — the user has to wait for it to finish before continuing, and if it hits an operation needing authorization along the way, the permission prompt passes straight through to the user. A background subagent runs concurrently with the main conversation; before launching, it asks what tool permissions it will need, and once approved and running, any operation beyond that authorized scope gets automatically denied without asking the user again. There's also nested spawning — a subagent can itself spawn another layer of subagents, currently supported up to a certain default depth to prevent runaway, uncontrolled layering.

04 · What should you do?

What does a Subagent actually mean for me, and when should I proactively define my own?

If you find yourself repeatedly asking Claude to do the same highly self-contained type of work — like consistently "review code against the same standard" or "run a fixed security-check process" — defining that role as a named subagent means that from then on, whenever a task matches this description, the main conversation automatically judges whether to delegate it, without you needing to re-describe how that role should behave each time.

If you're just a regular Claude Code user who has never defined a subagent yourself, that doesn't mean you're not already benefiting from this mechanism — a built-in command like /code-review already defaults to running as a subagent (in background mode), so you're already getting the context-cleanliness this provides. The real moment worth noticing is when you find the same conversation getting messier because you're switching between different kinds of tasks, or when you want to advance several unrelated pieces of work at once — that's the signal it's worth splitting some of that work off into subagents.

Real-World Example +

Claude Code's built-in /code-review command, following its August 2026 update, defaults to running as a background subagent: after the user issues the command, the review work proceeds in its own separate context window, with the file-by-file reading and analysis process not shown in the main conversation. The user can keep working on other tasks in the main thread while waiting, and the conclusion is returned to the main conversation once the review finishes.

Common Misconceptions +
✕ Misconception 1
× Misconception: A subagent is just a functional offshoot of the main conversation, essentially an extension of the same conversation, when actually: a subagent is a fully independent Claude instance with its own system prompt and tool list, and can even run a different model — the main conversation only sees the final summary it reports back, never the intermediate process
✕ Misconception 2
× Misconception: A background subagent can act completely autonomously with no restrictions, when actually: a background subagent is asked what tool permissions it needs before it even launches, and any operation during execution that exceeds that authorized scope is automatically denied — it's not unrestricted free execution
The Missing Link +
Direct Impact

The advantage is being able to isolate complex or multiple parallel tasks into their own independent context spaces, keeping the main conversation clean enough to sustain a long discussion, with background mode letting tasks run alongside the main conversation without waiting; the drawback is that once process details are isolated, they're no longer visible in real time — if you were used to judging a task's quality by watching its execution process, that visibility disappears entirely, leaving only the final result.

Ask a Question
Please enter at least 10 characters
Related Articles
Subagents Aren't Smarter Mini-Claudes — They Solve Isolation, Not Capability
advanced · Aug 31
When Subagents Actually Help — and When They're Just Overcomplicating a Simple Task
advanced · Aug 25
How Skills and Subagents Divide Labor: Not Either/Or, But Who "Knows" vs Who "Executes"
skill-library · Aug 25
Reviewing Superpowers: A TDD Framework That Literally Deletes Code Written Before Tests Exist
reviews · Aug 15
Related News
More Related Topics