How to Change Branch Name in Gitlab
- George Apostolov
- 05 Sep 2025
Guide
Check the branches you have in the repository first.
Type the command git branch and click Enter.
OR, type the command git branch --list and click Enter.
The one with the star icon (*) is the original branch name.
Type the command git branch -m, followed by the new name (feature-B, in this example), and then click Enter.
Notice how the current branch name has been updated to feature-B.
Type the command git branch to show the new branch name officially.
Create your first interactive demo in minutes
No credit card required • Start building today


