How to Change Branch Name in Gitlab
- George Apostolov
How to Change Branch Name in Gitlab: step-by-step 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.
Quick answer: To rename a branch in GitLab, check existing repository branches using the command git branch or git branch --list, identify the current branch marked with a star icon, and enter the command git branch -m followed by the new name to officially update it.
About this GitLab tutorial
Rename your GitLab repository branches quickly using simple command line instructions to update current branch names efficiently. This guide shows how to change Branch Name in Gitlab in 7 steps, starting with "Check the branches you have in the repository first" and finishing with "Type the command git branch to show the new branch name officially ". The interactive demo above is a click-through copy of the real GitLab interface, so you can rehearse each step before doing it in your own account.
Frequently asked questions
How many steps does it take to change Branch Name in Gitlab?
7 steps. Each one is listed in order above, and the demo highlights exactly where to click.
Can I try it without changing my own account?
Yes. Clicking through the demo doesn't touch your GitLab data or settings. Once you know the flow, repeat it in your own workspace.
This tutorial is filed under GitLab. Related guides: How to Check GitLab Version, How to clone gitlab repository and How to clone with ssh gitlab. Last reviewed 05 Oct 2026.
Create your first interactive demo in minutes
No credit card required • Start building today





