Article version: Enterprise Server 2.14

This version of GitHub Enterprise will be discontinued on This version of GitHub Enterprise was discontinued on 2019-07-12. No patch releases will be made, even for critical security issues. For better performance, improved security, and new features, upgrade to the latest version of GitHub Enterprise. For help with the upgrade, contact GitHub Enterprise support.

Enabling required status checks

Protected branches are available in public repositories with GitHub Free, and in public and private repositories with GitHub Pro, GitHub Team, GitHub Enterprise Cloud, and GitHub Enterprise Server.

Repository administrators can enforce required status checks before a branch is merged in a pull request or before commits on a local branch can be pushed to the protected remote branch.

Before enabling required status checks on a branch, you must first:

You can automatically enforce protected branch settings for some or all branches in your repository. For more information, see "Configuring protected branches."

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

  2. Under your repository name, 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 with a required status check using the drop-down menu.

    Selecting a protected branch drop-down menu

  5. Select Require status checks to pass before merging.

    Required status checks option

  6. Optionally, deselect Require branches to be up to date before merging. If selected, this ensures that the branch is tested with the latest code on the base branch.

    Loose or strict required status checkbox

  7. From the list of available status checks, select the ones you want to make required.

    List of available status checks

  8. Optionally, select Include administrators. This enforces the required status checks on the repository administrators.

    Include administrators checkbox

  9. Optionally, deselect Require branches to be up-to-date before merging. If selected, this ensures that the branch is tested with the latest code on the base branch.

    Loose or strict required status checkbox

  10. Click Save changes.

Tip: To successfully merge a pull request into a base branch that has required status checks enabled, the pull request's head branch must be up-to-date with the base branch.

Ask a human

Can't find what you're looking for?

Contact us