Delete a linked worktree entry and directory.
Section: Worktree Workflows
Remove a worktree
bash
bash
git worktree remove --force ../featureExplanation
Use `--force` only when the worktree has local changes or other blockers and you intentionally want it removed.
Learn the surrounding workflow
Compare similar commands or jump into common fixes when this command is part of a bigger troubleshooting path.
Related commands
Same sheet · prioritizing Worktree Workflows
Create a detached worktree at a commit
Check out a specific commit in a new working tree.
Create worktree and new branch together
Add a worktree and create a new branch from current HEAD.
Lock a worktree
Prevent a worktree from being pruned or accidentally removed.
Prune stale worktree administrative entries
Clean up references to missing worktree directories.
Delete ignored files too
Remove ignored and untracked files and directories.