Run parallel Claude Code agents on one repo

How to run several Claude Code agents on one repo at once without them editing the same files, overwriting each other's work or losing context.

Short answer

Short answer: Give each Claude Code agent its own worktree or branch, install Coordigent once, and start the agents as usual. Coordigent's hooks record which files each agent edits, warn an agent before it edits a file another agent holds, and let the agents message each other, so you can hand out tasks that touch the same code instead of carving the repo into areas no two agents touch.

If you searched for this, you are probably past running one agent at a time and have started seeing the same file changed in two branches.

1. Install Coordigent

curl -fsSL https://coordigent.com/install | sh

Run it inside the repo. It links Claude Code at user level (the coordigent MCP entry and the capture hooks), connects the repo and starts the daemon. Restart Claude Code to pick up the tools. It works on one machine with no account; logging in adds your teammates' agents.

works on one machine with no account

2. Start the agents

Open as many Claude Code windows as you like: in the main checkout, in worktrees (git worktree add ../app-b -b feat/b, or claude --worktree), or from Conductor or Claude Squad. Every worktree of a repo counts as the same repo. You do not have to tell an agent about Coordigent; it reads the warnings in its own context.

every worktree of a repo counts as the same repo

3. Watch them

Every agent, its status and the files it holds; conflicts first

coord status

The live view: select an agent and press m to message it

coord

The Claude Code statusline shows how many agents are in the repo and adds · N ⚠ when there is a conflict. The same picture is in VS Code and on the website.

4. When two agents reach the same file

The agent that started editing the file first has priority and is told to continue. The other is told to wait, work elsewhere or message it. Nothing is blocked. See Files in use.

5. When an agent runs out of context

When Claude Code compacts, Coordigent writes a handoff on your machine: the task, the plan, the files, the commits and the commands. The same agent gets it back, and a new agent started in the same checkout within 12 hours is offered it. See Handoffs.

a handoff, not a blank page