<- all tokdocs

Claude Code Agent Teams: Multiple AI Agents Coordinating Like a Dev Team

Watch on TikTok

View on TikTok ->

Anthropic released Agent Teams inside Claude Code, and it changes how the tool handles complex, multi-part tasks. Instead of one agent doing everything sequentially, Claude Code can now split work across multiple terminal sessions where agents collaborate like teammates.

How It Differs from Sub-Agents

Before Agent Teams, Claude Code could spawn sub-agents. A sub-agent receives a prompt from a parent agent, does focused work, and sends a response back. The parent controls everything.

Agent Teams works differently. You send a prompt, and Claude Code splits it into separate terminals, each with its own task. The agents can communicate with each other under the hood. Everything runs inside one Tmux session.

Claude Code Agent Teams overview showing a Lead agent connected to Agent-1, Agent-2, and Agent-3, with 4 agents, 1 shared task list, and direct messaging

Anthropic's documentation draws a clear line between the two approaches:

  • Sub-agents are best for focused tasks where only the results matter. Lower token cost because results are summarized back to the main context.
  • Agent Teams are best for complex work requiring discussion and collaboration. Higher token cost because each teammate is a separate Claude instance.

Anthropic documentation showing how to enable agent teams by setting CLAUDE_CODE_EXPERIMENTAL_AGENT_TEAMS to 1 in settings.json

How to Enable It

Agent Teams is disabled by default. To enable it, set the CLAUDE_CODE_EXPERIMENTAL_AGENT_TEAMS environment variable to 1. You can do this in your shell environment or through settings.json:

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

Once enabled, tell Claude to create an agent team and describe the task and team structure you want in natural language. Claude creates the team, spawns teammates, and coordinates work based on your prompt.

What It Looks Like in Practice

When running, the Tmux session shows multiple panes. Each agent has its own terminal, its own task, and awareness of what the other agents are working on. You can see each agent's progress, accept edits, and cycle between teammates.

Multiple terminal panes in a Tmux session showing agents building a Markdown Note App with separate panes for CSS, JavaScript, and assembly tasks, each working in parallel

In the demo shown, agents are building a React Storybook Component Library. The lead agent coordinates while individual agents handle Button, TextInput, Avatar, Card, and Modal components. They track dependencies between tasks (Modal is blocked by Button and Card) and notify the team lead when their work passes TypeScript checks.

A more detailed Tmux view showing the React Storybook build with a lead agent waiting for components, an Avatar Card Builder running TypeScript checks, and a Modal Component Build waiting on dependencies

Key Takeaways

  • Agent Teams splits complex tasks across multiple Claude instances that coordinate through shared task lists and direct messaging
  • Sub-agents are still the right choice for simple, focused tasks. Agent Teams is for work that benefits from discussion and parallel collaboration.
  • Enable it with a single environment variable, then describe your team structure in natural language

Published May 25, 2026. Writeup generated from a favorited TikTok.