Repository administrators can enable protected branches for limiting branch manipulation.

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

  2. In the repository's right sidebar, click Settings. Repository settings button

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

  4. Under Protected Branches, select the branch you want to mark protected using the drop-down menu. Selecting a protected branch drop-down menu

  5. Select Protect this branch. Protecting branch checkbox
  6. Click Save changes.

Further reading