Pull Request
A pull request proposes adding changes from one branch to another. It gives people a place to review the changes, discuss them, and run automated checks before merging.
Also known as: PR, merge request, MR, пулл-реквест
What is a pull request?
A pull request (PR) is a proposal to merge changes into a target branch. Think of it as a review page for a change that hasn't landed yet: it shows the diff (what was added, removed, or edited), explains the reason for the change, and records feedback and check results. Opening a PR does not change the target branch.
GitHub calls this a pull request; GitLab calls it a merge request (MR). It's a feature of the repository hosting platform, not a built-in Git operation. Despite the name, git pull does not open a PR: it fetches remote changes and integrates them into your local branch.
From branch to merge
Start by committing your changes to a working branch and pushing it to a remote repository. When you open the PR, choose both the source branch (where your changes are) and the target branch (where they should land). The target is often main, but it could be a release branch instead.
Reviewers can comment on specific lines, ask for changes, or approve the PR. If continuous integration (CI) is configured for the PR, you'll see results for checks such as tests, linting, or a build. Push a follow-up commit to the same source branch and the existing PR updates; you don't need to recreate it for each round of feedback.
A repository can require approvals, passing checks, or both before it allows a merge. An approval doesn't override a required failing test, and a green build doesn't count as a review. A PR can also be closed without merging if the team decides not to proceed.
Example: Make an empty state clearer
Suppose the search page looks broken when there are no results. Open a PR from show-empty-search-state into main with the title “Show a message when search returns no results.” In the description, explain what users see today, include a screenshot of the new state, and give reviewers a query they can use to reproduce it. Mention any tests you added. That gives reviewers a way to verify the behavior instead of guessing from the diff.
Where PRs help and what to watch for
Teams use PRs to review work before it lands and to keep a record of why decisions were made. In open source, contributors often push to a fork—a copy of the repository—because they don't have write access to the original. The PR then proposes merging from a branch in the fork into a branch in the original repository.
Keep a PR focused on one change reviewers can evaluate on its own. Mixing a bug fix with unrelated formatting makes it harder to see what changed the behavior; the regression test for the fix, on the other hand, belongs with it. Also, don't assume that a merged PR is already live. Deployment may happen automatically after merging, or it may happen later through a separate release process.
How it comes up in interviews
Expect practical scenarios rather than a definition alone. If someone asks what you'd do when a PR passes CI but a reviewer identifies an untested edge case, explain how you'd verify the case, add a test if appropriate, and push the fix to the same branch. Passing checks tell you what the existing checks covered; they don't settle every review concern.