Work with branches
Keep separate versions of a project and switch between them.
A branch is a saved copy of the whole project folder. Branches are part of Code and are separate from Git.
The name of the current branch appears under the project name. The main branch is called master.

Create a branch
- Open a file in the project.
- Click Branches next to the editor options.
- Click Create a new branch.
- Enter a name and press
Enter. - Confirm with Create branch.
Code moves you to the new branch.
Switch to another branch
- Click Branches.
- Click the branch.
- Confirm with Change branch.
Code stores the files of the current branch and loads the files of the other one.
A file that you add on one branch stays in the folder when you switch. Remove it by hand if you don't want it on the other branch.
Remove a branch
- Click Branches.
- Click the trash icon next to the branch.
- Confirm with Remove branch.
You can't remove the branch you are working on.