Complete Guide to Claude Code for PR Review (2026)

Published Updated

Claude Code can inspect a change before it leaves a laptop, inside a team-owned GitHub Actions job, or through Anthropic's managed pull-request service. Those paths share a product name while carrying different models, permissions, billing, and data routes. The useful first step is to separate them.

Claude Code is my main coding and orchestration environment. I use project instructions, hooks, and agent workflows to keep work inside repository rules. That daily use gives me a firm view of instruction drift: a reviewer needs short checks it can prove, plus a human who owns the release decision.

Claude Code Review at a Glance

Claude Code review paths checked on July 28, 2026.
Review Path Execution Location Billing Method Main Tradeoff
Local review Claude Code session Plan or API usage Manual and private
Claude Code Action GitHub runner Chosen provider Team owns workflow
Managed Code Review Anthropic service Extra usage Verified, higher cost

Three Ways to Review with Claude Code

The operating model comes before prompt tuning. A developer checking a local diff has a different goal from an organization that wants every selected pull request recorded in GitHub. The three review surfaces below carry different owners, costs, and security boundaries.

Managed Code Review

Anthropic's managed-review documentation, checked July 28, describes a Team and Enterprise research preview. An admin installs the Claude GitHub App, selects repositories, and chooses when reviews run.

The service reads the diff and surrounding codebase, posts inline comments, and creates a Claude Code Review check. Its check always has a neutral conclusion. Teams wanting a merge gate must parse the severity data in their own CI or keep an existing required approval.

Managed review suits a pull request that merits full-codebase analysis without the team maintaining a custom action. It carries a higher per-run bill, an average 20-minute wait, and a hosted data path. Those costs should attach to selected risk, not habit.

Claude Code Action

The official Claude Code Action documentation, checked July 28, says the Action runs on the team's GitHub Actions runner. It can review a pull request, answer questions, or perform bounded code work based on the event and prompt.

Authentication can use Anthropic directly, Amazon Bedrock, Google Vertex AI, or Microsoft Foundry. Anthropic's current GitHub Actions guide also documents workload identity federation for short-lived credentials, which avoids storing a long-lived Anthropic API key.

The Action gives a team more control over the runner, event, prompt, model provider, and token permissions. That control also transfers more operational ownership to the team. Someone must pin the action safely, review permission changes, prevent untrusted text from steering privileged work, and watch provider spend.

Local Review

Local review happens inside the same Claude Code environment used to inspect and change the repository. A developer can ask Claude to review the current diff, run the /code-review command before pushing, or focus a pass on one contract such as tenant isolation.

This is the smallest trial because it adds no GitHub App and no new organization-wide trigger. The findings stay with the developer until they decide what belongs in a commit or pull request.

Local review also has the widest variation. The result depends on the selected model, session instructions, available tools, permission mode, and context already in the conversation. Record the exact diff and review request if the team wants to compare runs fairly.

How Managed Review Works

When a managed review starts, several agents inspect the diff and nearby code in parallel. Each looks for a different failure class. A verification stage checks candidate findings against the code, removes duplicates, ranks the rest, and posts surviving items by severity.

Anthropic currently labels findings Important, Nit, or Pre-existing. Important means a bug worth fixing before merge, while Nit covers a minor issue. Pre-existing marks a problem already present in the repository so the current pull request does not take false blame.

The service can run once when a pull request opens, after every push, or by comment. The trigger details below were checked in Anthropic's docs on July 28:

Review Trigger Run Behavior Billing and Rerun Effect
Initial PR creation Single opening review One billed run
Every push Reviews each update Multiplies by pushes
@claude review Single requested review No push subscription
@claude review once Same one-shot behavior No push subscription
@claude review always Reviews and subscribes Future pushes run

The July 2026 behavior makes the bare command a safer one-shot control for long-running pull requests. Use @claude review always only when later pushes should trigger fresh reviews and charges. The explicit once form remains an alias for the bare command.

Control the Review with REVIEW.md

The older page's strongest material was its REVIEW.md explanation, and the current docs still back it. CLAUDE.md supplies project context for all Claude work. REVIEW.md sits at the repository root and changes managed review behavior only.

Anthropic injects REVIEW.md directly into every review agent as its highest-priority instruction block. Imports are not expanded, so the file must contain the rules it expects the agents to use. A compact backend example can look like this:

# Review instructions

## Important findings
- Unscoped tenant queries
- PII in logs or errors
- Migrations without a rollback path

## Skip
- Generated files and lockfiles
- Formatting and type errors caught by CI

## Evidence
- Cite the source path and call chain
- Suppress a claim that cannot be verified

Each rule describes a durable outcome and avoids temporary function names. The skip list protects reviewer time from low-value generated content. The evidence bar asks the agent to prove a cross-file claim before a developer spends time reproducing it.

Set a nit cap if prose, config, or tests attract endless polish. Another useful rule suppresses fresh nits after the first review so a one-line fix does not start a new style loop. Keep business and architecture context in CLAUDE.md, where it also helps ordinary Claude Code sessions.

What Claude Code Can Catch

Managed review is built for logic errors, security flaws, broken edge cases, and regressions that need surrounding code. A changed permission check may look safe in the diff while a caller passes the wrong identity. A migration may compile while an older worker still expects the prior schema.

The verification stage is the main architectural appeal of managed review. A plausible comment must survive another inspection step before it reaches the pull request. That lowers the chance of an unchecked guess becoming team work, although Anthropic does not promise that every surviving comment is correct.

Local review can use tools from the active session. It may run a targeted test, inspect a type, search all call sites, or compare behavior with a requirement file. The quality rises when the prompt names the contract and asks for source evidence.

Claude Opus 5 changes the current model choice for local review. Anthropic's July 24 release post, checked July 28, says Opus 5 became the default on Max and the strongest model on Pro. Anthropic cites verification and root-cause work as model strengths, while leaving the managed service's exact model unspecified.

Where Claude Code Review Struggles

A multi-agent pass still lacks product intent that never appears in the repository. It can trace a pricing calculation and miss that the formula violates a sales contract. It can approve a safe local change that breaks an operational runbook stored elsewhere.

Managed review carries queue time and variable cost. Every-push triggers can turn a busy pull request into several bills. A failed run ends neutrally and does not retry on its own, so the lack of a blocking check cannot be read as a clean review.

REVIEW.md can create its own noise when it grows into a second handbook. Conflicting rules, stale path names, and long lists weaken the checks that matter. Review the file when the code boundary changes and delete rules that deterministic CI now enforces.

Claude can also refuse or redirect some security work. Anthropic's Opus 5 post, checked July 28, says narrow cyber classifiers block some binary scanning, penetration testing, and exploit generation. It reports about 85% fewer interventions than Fable 5 and a default fallback to Opus 4.8 for flagged requests.

Claude Code Review Costs

Pricing needs three separate rows because a Claude subscription, API tokens, and managed review are different bills. The figures below link to Anthropic's official pages and were checked July 28, 2026.

Billing Path Current Price Applies to Workload
Claude Pro $17/mo annual, $20/mo monthly Local Claude Code
Claude Max From $100/mo Higher plan usage
Opus 5 API $5 input, $25 output per MTok API workflows
Managed review $15 to $25 per review Each review run

At a $20 midpoint, twenty one-shot managed reviews cost about $400. Three review-triggering pushes across each of those pull requests bring the rough total to $1,200. The selected trigger policy controls that threefold cost difference.

Claude Code Action follows the chosen provider's model and runner billing. Local plan usage competes with the developer's other Claude work. A fair pilot tracks total review cost and triage time because one seat price and one managed run measure different workloads.

Security, Data, and Permissions

Managed review processes code on Anthropic infrastructure and is unavailable when Zero Data Retention is enabled. The GitHub App asks for repository contents plus pull-request and issue permissions. Start with selected repositories and confirm the organization's retention and access settings.

The Action runs on a team runner, yet model requests still leave for the configured provider. Review the runner image, outbound network, secrets, logs, checkout behavior, and token permissions. Workload identity can remove a stored API key while leaving the rest of that boundary to the team.

Keep review read-only during the first trial. A workflow that can post a finding needs less authority than one that can push a fix. Separate those jobs, and require a developer to verify the issue before any write-enabled task runs.

Security prompts should name the authorized repository, defensive purpose, expected evidence, and excluded actions. That context helps the model understand the task and gives the human reviewer a clear standard for rejecting an unsafe detour.

Pull-request text, source comments, fixtures, and generated files can contain instructions that compete with the workflow prompt. Treat them as untrusted data, keep privileged rules in reviewed configuration, and require tool evidence for claims that cross file or service boundaries.

Test Each Claude Review Surface

Use the hub's four-week method for the common sample and outcome labels. Start locally on one clean diff and one known defect, recording the model, instructions, files available, findings, and checks run.

The next step is choosing one shared review surface. A team that already owns GitHub Actions can try the Action with read-only permissions. A Team or Enterprise organization can enable managed review on one repository with @claude review once.

  1. Limit scope: One repository and manual triggers.
  2. Add rules: Three stable checks in REVIEW.md.
  3. Measure: Verified defects, false positives, cost, and triage time.
  4. Trigger check: Compare one-shot commands with @claude review always and record the extra push-triggered runs.

Keep tests, static analysis, and required human approval in place throughout the pilot. Recheck REVIEW.md after several pull requests and remove any rule that produces repeated guesses.

Record failed and neutral runs alongside successful ones. A review lane that completes only on small diffs can look accurate while disappearing on the changes that need it most. Completion rate, queue time, and cost belong beside accepted findings in the rollout decision.

Claude Code Review Verdict

Claude Code is strongest when each review surface has a distinct job. Use /code-review for a private developer pass, the Action for a team-owned runner and provider, and managed review for costly pull requests that justify multi-agent verification. A short REVIEW.md sharpens the hosted lane; accountable approval stays with a person.

FAQ

Who can use managed Claude Code Review?

Anthropic lists managed Code Review as a research preview for Team and Enterprise subscriptions. An organization admin enables it and selects repositories, while organizations with Zero Data Retention enabled cannot use the hosted service. Individuals can still review locally, and teams can build a separate workflow with Claude Code Action.

What is the difference between CLAUDE.md and REVIEW.md?

CLAUDE.md supplies project context for Claude Code work and can produce nit-level findings when a change breaks its rules. REVIEW.md applies only to managed review. Anthropic injects it into every review agent at highest priority, so it is the stronger place for severity, skip, evidence, and reporting rules.

How long does a managed review take?

Anthropic reports an average completion time of about 20 minutes. Pull-request size, repository context, and the findings that need verification can move that figure. The check run records progress and ends with a neutral conclusion, so a slow or failed review does not block the pull request by itself.

Does managed review use Claude Opus 5?

Anthropic does not name one fixed model for its managed multi-agent review service. Opus 5 became the default model on Claude Max and the strongest model on Claude Pro on July 24, 2026, which applies to local Claude Code work. Treat the managed pipeline as a separate product fact.

Can Claude Code review run on a team runner?

The official Claude Code Action can run on a GitHub Actions runner and send model requests through the provider you configure. It supports Anthropic, Amazon Bedrock, Google Vertex AI, and Microsoft Foundry. The team owns workflow permissions, authentication, network access, prompt scope, and the provider bill.

Features, access, model details, and prices on this page were checked against official Anthropic sources on July 28, 2026.

Sources

  1. [1]
  2. [2]
  3. [3]
  4. [4]