What Is PR in Coding? A Plain-English Guide
Key takeaways
- A PR, or pull request, is a proposal to merge changes from one git branch into another, opened so the diff can be reviewed, tested, and discussed before it lands.
- PRs give you three gates before code reaches main: a readable diff, review comments, and CI checks that fail on the branch instead of main.
- A commit is one snapshot of code; a PR is the proposal to merge a branch of commits, and GitHub's pull request is identical to GitLab's merge request.
- A good PR does one logical thing, has a title that reads like a commit message, includes tests, and keeps the diff small enough to review carefully.
- When coding agents write the code, the PR is your human checkpoint: read the diff, run the tests, and require a handoff note instead of trusting the agent's summary.
What is PR in coding? A PR, or pull request, is a proposal to merge changes from one git branch into another, opened so the diff can be reviewed, tested and discussed before it lands. When your contributors are coding agents running in parallel sessions, PRs are how you keep every change visible and checkable before it touches main.
What does PR stand for in coding?
PR means pull request: a proposal to merge one branch's changes into another, opened so the diff can be reviewed and tested before it lands. GitHub's docs describe it as a way to propose and collaborate on changes to a repository, and that definition holds across git hosts (About pull requests). The name is slightly misleading. You are not asking for your changes to be "pulled" manually; opening a PR tells the host "here is a branch, compare it against the base, run the checks, and let someone approve or reject the merge." If you run several agent sessions, PRs are where each agent's work becomes inspectable. Instead of reading chat logs to reconstruct what an agent did, you open the PR and read the diff. Tools like KanbanMCP build on this by letting agents claim a card, do the work, and leave a handoff note, so the PR lands with context attached rather than a bare "done".
Why do developers use pull requests instead of pushing directly?
Pushing straight to main works until two sessions touch the same file. A pull request turns each unit of work into something you can inspect, test, and undo before it lands. Three gates do the heavy lifting.
The review gate
A PR is a diff with a discussion attached. You read what actually changed, not what an agent claims it changed, and leave comments before anything merges. For solo work, the review is you: a two-minute read of the diff catches most of what a handoff note will not.
The CI gate
Tests, linters, and builds run against the branch before merge. If an agent's change breaks something, the PR fails red instead of your main branch failing at 2am. You can require checks to pass before merging, so broken code never reaches the branch other agents are branching from.
Why this matters more when agents write the code
Agent-written code is usually plausible and occasionally wrong in ways you only spot in the diff. The PR is your human review checkpoint: you steer from the same board, reject what misses, and merge what holds up. It also gives you a revertable unit — one merge, one revert. If you are weighing whether the gate is worth the overhead, the tradeoff is laid out on our pricing page alongside what each plan includes.
What are the parts of a pull request?
A pull request has seven visible parts: the source branch, a title, a description, the diff, review comments, CI checks, and the merge button. Every platform arranges them the same way, so learning them once covers GitHub, GitLab, and anything else.
Branch and title
The branch name tells you what the change is: fix/login-timeout beats patch-3. The title should read like a commit message in the imperative mood, one line, no ticket prefix needed if the description links it.
Description and linked issue
The description answers three questions: what changed, why, and how you tested it. Link the issue so the PR closes it automatically on merge. GitHub's own walkthrough covers this flow in detail (creating a pull request).
The diff
The diff is the actual work: every added and removed line, side by side. Reviewers (human or agent) work from the diff, not the description, so keep it small. When three or more agent sessions run in parallel, each one should own a branch off its own worktree so the diffs never overlap.
Review comments
Review comments attach to specific lines in the diff, which is what makes them useful. An agent can read them, push a fix to the same branch, and the diff updates in place. That loop, comment to fix to re-review, is the core of human review even when the contributor is a machine. It is also where a board like KanbanMCP earns its keep: the agent claims a card, opens the PR, and leaves a handoff note so the next session picks up the review comments without you re-pasting context.
CI checks and merge
CI checks run your tests and linters on the PR branch before anyone merges. Once checks pass and approvals land, the merge button appears. Green checks plus a clean diff is the whole gate; nothing else in the PR matters at merge time.
How does the PR review and merge process work step by step?
1. Branch off main
Create a branch from the latest main: git checkout -b fix-login-timeout. One branch per unit of work, so a diff stays reviewable. If you run agents in parallel, give each agent its own branch, usually paired with its own worktree so sessions never touch the same checkout.
2. Open the PR
Commit, push, then open a pull request on GitHub or GitLab. The description should say what changed, why, and how you tested it. When an agent wrote the code, have it draft that description itself and list anything it is unsure about.
3. CI runs
Your CI pipeline runs tests, linting and type checks on the branch. A green check means the automated gates passed; a red X means fix it before anyone reads a line. Treat CI as the reviewer that never gets tired.
4. Review and iterate
A human (or a second agent acting as reviewer) reads the diff and leaves comments. The author pushes fixes, which update the same PR. Repeat until approved. If your reviewer is an agent, keep the loop tight: request changes, let the claiming agent address them, then re-review.
5. Merge and clean up
Once approved and green, merge. Squash-merge keeps history readable when agents made many small commits. Delete the branch, pull main locally, and close the loop. If you track work on a board, move the card to done; on KanbanMCP the agent marks the card done and leaves a handoff note for the next session. For agent-specific setup, see the Claude Code integration.
PR vs merge request vs commit: what's the difference?
A commit is one snapshot of your code. A PR is the proposal to merge a branch of those commits into another branch, with review and checks attached.
PR and merge request are the same thing with different names: GitHub calls it a pull request, GitLab calls it a merge request. GitLab's docs define a merge request as a proposal to merge changes from one branch to another, which is exactly what a GitHub PR does.
| Term | What it is | Where you see it |
|---|---|---|
| Commit | One saved snapshot with a message | Git itself |
| PR / merge request | Proposal to merge a branch, with review and CI | GitHub / GitLab |
| Branch | The line of commits the PR proposes | Git itself |
The distinction matters when you run parallel agent sessions: each agent works on its own branch and commits, and the PR is where you review the combined result before it lands.
What makes a good pull request?
A good PR does one thing, has a title that says what it does, a description that says what and why, tests that prove it works, and a diff you have actually read yourself before asking for review. If you cannot summarise the change in one sentence, it is probably two PRs.
The reviewable-PR checklist
- One logical change per PR. No drive-by refactors mixed in.
- Title reads like a commit message: "Add retry to webhook delivery", not "fixes".
- Description covers what changed, why, and how you tested it.
- Tests included, or a one-line note on why not.
- You re-read your own diff before opening. Comment on anything that needs context.
- Diff size stays reviewable. If it is over ~400 lines, consider splitting.
Extra rules when an agent opened the PR
Agents write diffs fast and describe them confidently, so the description is not evidence. Check the diff against the task, run the tests yourself, and make sure the agent only touched the files it claimed. Require a handoff note in the PR body: what was attempted, what was skipped, what the next session should know. If the agent worked in a worktree, confirm the branch is rebased on your main before merge. Small scope matters more here, because a large agent-generated diff is exactly the one nobody reads carefully.
How do PRs fit into code review and CI/CD workflows?
A PR is the unit your pipeline runs against. Open one and CI kicks off: lint, type checks, tests, sometimes a preview build. If anything fails, the PR shows it before you merge. The branch-then-merge mechanics behind this are the standard workflow described in the Pro Git book.
Merge is the deploy trigger. Once a PR lands in main, your pipeline builds and ships, so a broken main usually means something merged without CI passing.
When the contributor is an agent, CI is your review. You read the diff and the test results instead of trusting the handoff note. If you run several agents in parallel, each should work on its own branch and open its own PR so checks stay isolated per card.
How do PRs work when you run several coding agents in parallel?
One branch per agent session
Give each agent its own branch or worktree and have it open its own PR when done. The PR is the unit of human review: you read the git diff in the morning, leave comments, and the agent picks them up. Keep the PR description short and factual so the next session (or you, a week later) can recover the context.
When a PR list stops being enough
With three or more agent sessions running, the PR list only shows finished work. It says nothing about which agent claimed which card, what is in progress, or what the handoff note said. That is the gap a board fills: KanbanMCP and similar tools let agents claim a card, do the work and leave a note for the next one, while you steer from the same board.
Where a board falls short: it is another tool to keep in sync with git, and if the board drifts from the actual branches, agents inherit stale state. If you run two sessions, a CLAUDE.md and a handover prompt are honestly enough. A board earns its keep once parallel sessions outgrow your memory of who is doing what. The practical test is simple: if you can still reconstruct the current state of all work in under a minute from the PR list alone, you do not need a board yet. The moment you find yourself opening three terminal tabs and scrolling git log to figure out which agent owns which branch, the board has started paying for itself. Most solo developers hit that point somewhere between two and five concurrent agent sessions, and it arrives faster than expected because agent sessions are cheap to start and easy to forget.
FAQ
Is a PR the same as a merge?
No. A merge is the act of combining one branch into another. A PR is the proposal to do that, wrapping the merge in review, CI checks, and discussion. You can merge without a PR on most hosts, but you lose the diff review and the green checks that gate what lands on main.
Can one PR contain multiple commits?
Yes. A PR shows every commit on the source branch, stacked and reviewable as one diff. Agents in particular tend to produce many small commits while iterating. If the history gets noisy, squash-merge at the end so main receives a single clean commit instead of ten 'fix typo' ones.
How long should a pull request stay open?
As short as review allows. Small, fresh PRs get read carefully; ones that sit for days pick up conflicts with main and stale context. Aim for same-day review on solo or agent work. If a PR lingers because it is too big to review, that is a signal to split it.
Should I open a PR for work only my coding agent will touch?
Yes, especially then. The PR is your checkpoint on code an agent wrote: the diff shows what actually changed, CI proves the tests pass, and one merge gives you one revertable unit. Without it, you are trusting the agent's summary instead of reading the work.
What does 'LGTM' mean in a PR review?
LGTM stands for 'looks good to me'. It is a reviewer's approval, signaling they read the diff and found nothing blocking. On GitHub it usually accompanies a formal approve review. Treat it as a human judgment on the diff, not on the description, which matters doubly when the author is an agent.