👋 We've unified all of GitHub's product documentation in one place! Check out the content for REST API, GraphQL API, and Developers. Learn more on the GitHub blog.
Article version: Enterprise Server 2.19

Reverting a pull request

You can revert a pull request after it's been merged to the upstream branch.

Were you able to find what you were looking for?

Reverting a pull request on GitHub Enterprise creates a new pull request that contains one revert of the merge commit from the original merged pull request.

Note: You may need to use Git to manually revert the individual commits if:

  • Reverting the pull request causes merge conflicts
  • The original pull request was not originally merged on GitHub Enterprise (for example, using a fast-forward merge on the command line)
  1. Under your repository name, click Pull requests.
    Issues and pull requests tab selection
  2. In the "Pull Requests" list, click the pull request you'd like to revert.
  3. Near the bottom of the pull request, click Revert.
    Revert pull request link
  4. Merge the resulting pull request. For more information, see "Merging a pull request."

Were you able to find what you were looking for?

Ask a human

Can't find what you're looking for?

Contact us