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
Configuring Pre-merge Checks
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
Configuration
Pre-Merge Checks can be configured via web interface or using.coderabbit.yaml file.
- Web Interface
- Configuration File
Configure Pre-Merge Checks through the CodeRabbit dashboard:
Navigate to Settings
In CodeRabbit, go to Settings ā Review ā Pre-Merge Checks (org or repo scope)
Add Custom Checks
Add Custom Checks:
- Name (⤠50 chars, unique within the org)
- Instructions (⤠1000 chars; natural language)
- Mode (off | warning | error)
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.
You can restrict who can ignore failed checks by setting
reviews.pre_merge_checks.override_requested_reviewers_only: true (default: false). When
enabled, only requested reviewers (not the PR author) can use the checkbox
or @coderabbitai ignore pre-merge checks, and CodeRabbit records who
performed the override for auditability.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.