LALaith Al Abbadi Book a call
Guide · 8 min read

Claude Code agent teams: how they work and when to use them

Agent teams let one Claude Code session act as a lead that spins up several teammates. Each has its own context, and they share a task list and message each other. Used well, they speed up research, review and parallel feature work. Used badly, they burn tokens. Here's how to use them well.

By Laith Al Abbadi, Fractional CTO & AI expert · Updated 15 November 2026

Status: agent teams are an experimental Claude Code feature and are disabled by default. Details can change, so always check the official agent teams docs. This guide reflects them as of November 2026.

What agent teams are

An agent team has four parts:

  • Team lead: your main Claude Code session. It creates the team, assigns work and combines the results.
  • Teammates: separate Claude Code instances, each with its own context window. They load your CLAUDE.md, MCP servers and skills, but not the lead's conversation history.
  • Shared task list: tasks are pending, in progress or completed, and can depend on other tasks. Teammates claim unblocked tasks, and the lead can also assign them.
  • Mailbox: teammates message each other and the lead directly, and you can message any teammate yourself.

How to enable agent teams

Set the environment variable in your shell, or in settings.json:

{
  "env": {
    "CLAUDE_CODE_EXPERIMENTAL_AGENT_TEAMS": "1"
  }
}

Then, in an interactive session, ask for a team in plain language, for example:

Spawn three teammates to review this PR: one focused on security,
one on performance, one on test coverage. Have them share findings
and challenge each other before reporting back.

Teams need an interactive session. Claude doesn't spawn teammates in non-interactive -p mode.

Display modes

  • In-process (default): all teammates run in your terminal. Use the agent panel to select a teammate and message it, and Ctrl+T to toggle the task list.
  • Split panes: each teammate gets its own pane via tmux or iTerm2. Configure with teammateMode in settings.

Agent teams vs subagents

SubagentsAgent teams
ContextOwn window, results returned to the callerFully independent sessions
CommunicationReport back to the main agentMessage each other directly
CoordinationManaged by the main agentSelf-coordinate via shared task list
Token costLowerSignificantly higher (each teammate is a full instance)
Best forFocused jobs where only the result mattersWork that benefits from discussion and parallel ownership

When agent teams are worth it

  • Research and review: several lenses on the same code or question, debated before a conclusion.
  • Debugging with competing hypotheses: teammates each try to prove their theory and challenge the others.
  • New modules or features where each teammate owns separate files.
  • Cross-layer work: front end, back end and tests in parallel.

Avoid teams for sequential tasks, edits to the same files (teammates can overwrite each other), or work with lots of dependencies. A single session or subagents is cheaper and more reliable there.

Best practices from production use

  1. Start with 3–5 teammates. Token cost grows linearly with team size and returns diminish quickly.
  2. Give each teammate real context in its spawn prompt: goal, files, constraints and the definition of done.
  3. Size tasks as self-contained units with a clear deliverable, around 5–6 tasks per teammate.
  4. Split by file ownership to avoid edit conflicts.
  5. Pre-approve safe, common operations so permission prompts don't stall the team (teammates inherit the lead's permission mode, so be deliberate).
  6. Use quality-gate hooks such as TaskCompleted and TeammateIdle to enforce tests or checks before work is accepted.
  7. Steer, don't abandon. Check in on the lead periodically rather than letting a team run unattended for hours.

Known limitations

  • One team per session, and teammates can't spawn their own teammates.
  • The lead is fixed for the session's lifetime.
  • /resume and /rewind don't restore in-process teammates.
  • Task status can lag, and shutdown can be slow.
  • Split panes need tmux or iTerm2.

Frequently asked questions

How do I turn on Claude Code agent teams?

Set CLAUDE_CODE_EXPERIMENTAL_AGENT_TEAMS to 1 in your environment or in the env block of settings.json, then ask Claude in an interactive session to spawn a team.

What's the difference between agent teams and subagents?

Subagents are workers that do a focused job and report results back to the main agent. Agent teams are independent Claude Code sessions that share a task list and message each other directly. Teams are more powerful and use more tokens.

How many teammates should I use?

The documentation suggests starting with 3–5 teammates for most workflows. Token costs scale with the number of active teammates.

Are agent teams production-ready?

They're experimental. They work well for research, review and parallel feature work, but have known limitations around session resumption, task status and shutdown.

Want your team using Claude Code properly?

I set up Claude Code for engineering teams with CLAUDE.md, skills, subagents, MCP servers, hooks and agent-team workflows. Book a call.

Book a call with Laith
Book a call