Skip to content
Mastering Claude

Home / Everyday moves

Everyday moves10 minApplication

Running in parallel: worktrees, model and fast mode

A git worktree isolates a parallel session on its own branch, and the --worktree flag now automates the whole thing, where previously only the manual git worktree add gesture existed.

A git worktree opens a second checkout of the same repository, on its own branch, in a separate folder. Two Claude Code sessions can thus work in parallel without one writing into files the other has mid edit.

The move now built in natively

This move is now built in natively to Claude Code, without needing to call git worktree yourself for the common case. The command claude --worktree feature-auth (or its short alias -w) automatically creates an isolated worktree under .claude/worktrees/feature-auth/, on a new branch named worktree-feature-auth, and starts the session directly inside it.

claude --worktree feature-auth
# creates .claude/worktrees/feature-auth/ on the worktree-feature-auth branch
# and starts the session in that folder

The manual move, git worktree add, stays valid and necessary in two cases the shortcut does not cover: starting from a specific existing branch, or placing the worktree outside the repository. Resuming a session in its worktree is automatic with --continue, --resume and in interactive mode, and Claude can itself create or switch worktrees through a dedicated tool, with confirmation asked as soon as it moves outside the .claude/worktrees/ folder.

The model is chosen on difficulty, fast mode on cost

In each worktree, the model choice stays independent: a mechanical, repetitive task goes to a lighter model, a task requiring judgement or adversarial verification goes to the most capable model. Fast mode, enabled by /fast, is a research preview available only on Opus 5 and Opus 4.8, absent from Sonnet, from Haiku, and now also from Opus 4.7, where support was removed after a deprecation period. It speeds up output by up to 2.5 times, at a rate billed separately in usage credits, ten dollars per million input tokens and fifty in output, exactly double the standard rate for Opus 5 and Opus 4.8, five dollars in input and twenty five in output on the Claude pricing page. The mode remains out of reach on Bedrock, Vertex, Foundry and Claude Platform on AWS, and it requires usage credits enabled on the account; for a Team or Enterprise plan, it stays disabled by default until an account holder with the Owner role enables it for the organisation. Enabling this mode charges once for the full cost of the conversation context already accumulated, in tokens not yet cached: this cost is lower when fast mode is enabled from the very start of a session, but disabling it and re-enabling it later does not repeat this charge. Multiplying sessions across worktrees therefore also multiplies this potential cost by however many sessions are running fast mode in parallel. Resuming a long command in one of these worktrees follows the same background task logic as headless mode and background tasks.

Figure 1

A single session against a session in an isolated worktree

Isolation and cost of a parallel sessionCode isolationRisk of collision between sessionsSetup
Single session in the main repositoryA single copy of the code, all changes get mixed togetherTwo sessions on the same repository write into the same filesNo extra command
Session launched with claude --worktreeAn isolated checkout under .claude/worktrees, on its own branchEach session writes into its own folder, nothing overlapsA single command, branch and folder creation is automatic
The comparison crosses three criteria, code isolation, risk of collision between sessions and setup, between a single session in the main repository and a session launched with claude --worktree.
Calibrate it yourself

A developer launches claude --worktree rapport-mensuel in her repository, then launches claude --worktree tableau-bord from a second terminal window opened on the same repository.

Write, in one sentence, what this situation establishes, and in one sentence what it does not establish.

What to remember
  • claude --worktree (or -w) now automatically creates and isolates a checkout on its own branch, where previously only the manual git worktree add gesture existed.
  • The manual git worktree add gesture remains necessary to start from a specific existing branch or to place the worktree outside the repository.
  • --continue, --resume and interactive mode automatically resume a session in its own worktree, with no extra command.
  • Fast mode, enabled by /fast, exists only on Opus 5 and Opus 4.8, no longer on Opus 4.7 where it previously existed and support has now been removed, and it charges double the standard rate, ten dollars in input and fifty in output, subject to usage credits enabled and excluding Bedrock, Vertex, Foundry and Claude Platform on AWS.
  • Enabling fast mode from the very start of a session charges a lower context cost than enabling it midway through, but disabling it and re-enabling it later does not repeat this charge.
Do this now

From an existing git repository on your machine, run claude --worktree essai-parallele in a terminal, check that the .claude/worktrees/essai-parallele/ folder has appeared on its own branch, then close that session without merging anything.

Check the source

Every datable claim in this lesson links here to the public text behind it. A source that does not open proves nothing.