Pre-merge checks are available in Preview for Pro plan users. During the
Preview period, you can configure up to 5 custom checks per organization.
Why use Pre-Merge Checks?
- Consistent standards: Enforce naming, documentation, and change-management hygiene across every PR.
- Safer merges: Catch breaking API changes, security gaps, or policy violations before they land.
- Team-specific guardrails: Encode architectural patterns, compliance rules, or business logic as custom checks.
- Faster reviews: Surface blocking issues early in the PR Walkthrough so reviewers can act quickly.
Built-in Checks
CodeRabbit includes four standard checks that address common organizational needs:Docstring Coverage
Verify PR docstring coverage against a configurable threshold (80% by
default)
Pull Request Title
Validate PR titles accurately reflect changes made and follow your specified
requirements
Pull Request Description
Verify descriptions follow the template specified in your Git platform
Issue Assessment
Verify PRs address linked issues without containing out-of-scope changes
Custom Checks
Go beyond built-in checks by defining your own validation logic using natural language instructions. Custom checks leverage AI to understand and validate complex requirements specific to your team’s policies, such as:- Detecting sensitive data in logs
- Enforcing documentation for breaking changes
- Validating database migration patterns
- Ensuring compliance with language migration policies
Configuration
Enforcement Modes
Each check can be configured with one of three enforcement modes:off: Check is disabledwarning: Display warnings but don’t block merges (default)error: When paired with Request Changes Workflow, block merges until resolved or manually overridden
UI Configuration
Configure Pre-Merge Checks through the CodeRabbit dashboard:1
Navigate to Settings
In CodeRabbit, go to Settings → Review → Pre-Merge Checks (org or repo scope)
2
Configure Built-in Checks
Update configuration and enforcement modes for Built-in Checks
3
Add Custom Checks
Add Custom Checks:
- Name (≤ 50 chars, unique within the org)
- Instructions (≤ 1000 chars; natural language)
- Mode (off | warning | error)
4
Apply Changes
Click Apply Changes to save. The new checks are applied to subsequent reviews.
YAML Configuration
For version-controlled configuration, add checks to your.coderabbit.yaml file:
YAML
Results in the Walkthrough
Pre-Merge Check results appear alongside CodeRabbit’s analysis in the PR Walkthrough with clear visual organization for quick assessment. Results are organized into two tables:- Failed checks — prominently displayed to show errors and warnings requiring attention
- Passed checks — expandable to review checks that were validated successfully
- Objective — the name of the check being evaluated
- Status — one of:
- ❌ Error — failed and will block merge when Request Changes is enabled
- ⚠️ Warning — failed but non-blocking
- ✅ Passed — requirements met
- ❓ Inconclusive — incomplete instructions or insufficient information to decide
- Explanation — why the check passed or failed
- Resolution — what the author can do to remediate
Unblocking a PR
If Request Changes Workflow is enabled and a check in Error mode fails, the PR is blocked until the issue is resolved or you explicitly ignore it. To ignore, select the Ignore failed checks checkbox in the PR Walkthrough. The PR is then unblocked and the affected rows are tagged [IGNORED] for traceability.The override applies only to that PR. Future PRs will still enforce checks as
configured.
Manual commands
Trigger pre-merge checks manually using chat commands:Run All Checks
Test Custom Check
Ignore failures
See Manage code reviews for more commands and behaviors.