# Git worktree

> A second working directory attached to the same repository, so two agents can work on different branches at once without clashing.

_Updated November 23, 2026_

`git worktree add ../feature-b feature-b` checks out another branch in another folder, sharing the same history. Running one agent per worktree is a simple way to parallelize work on one repository.

## Keep reading

- [Subagent](https://envhaven.com/glossary/subagent)
- [Agentic coding](https://envhaven.com/glossary/agentic-coding)
- [Background agent](https://envhaven.com/glossary/background-agent)

Source: https://envhaven.com/glossary/git-worktree
