GitHub – How to Display a Branch Other Than Master on Project Home Page

github

The regular main page (https://github.com/username/repo) for a repo on GitHub displays the master branch by default.

Is there a way to make it display another branch as the default, say if I make a branch called main, default, head etc.?

Best Answer

Repository Administration - Options - Settings - Default branch select-box

Change "master" to any (existing) branch

enter image description here