The default branch is considered the base branch in your repository, against which all pull requests and code commits are automatically made, unless you specify a different branch.

Your default branch is named master. If you have admin rights over a repository on your GitHub Enterprise instance, you can change the default branch on the repository.

  1. On GitHub Enterprise, navigate to the main page of the repository.

  2. Repository settings buttonUnder your repository name, click Settings.

  3. Repository options sub-menuIn the left menu, click Branches.

  4. Default branch dropdown selectorIn the default branch sidebar, choose the new default branch.

You can only switch between branches that already exist on your GitHub Enterprise instance. To create a new branch through the UI, see "Creating and deleting branches within your repository".

Warning: This affects your trunk branch contents on the Git-Subversion bridge and the HEAD you'd see when you git ls-remote this repository's upstream URL.