Renaming the default branch from master

Many communities, both on GitHub and in the wider Git community, are considering renaming the default branch name of their repository from master.

This is a place where the entire GitHub community can discuss the benefits and drawbacks of renaming the default branch.

Git and GitLab are also discussing this change:

I think the possibility of setting a custom default branch name at an organization or user level is unquestionably great. But should the change from master to main as the default branch name for new repository be an opt-in or opt-out?

GitHub will have a great support for whatever default branch name you choose, but other tools will access the repositories hosted there and might expect the default branch to be master.

CI/CD tools and their configurations generally have explicit knowledge about the master branch and trigger pipelines based on it. Changing it to main might require reconfiguration of those tools and sometimes patches in the source code.

This would also break compatibility with legacy tools and systems that still need to be used and are not able to be updated.