View as Markdown

Merge Queue Overview

Deterministic, parallel, and resource-aware merging for your team.


Mergify’s merge queue prevents broken main branches by ensuring every PR is tested against the latest code before merging. No more “it worked on my branch” failures.

Get started in 5 minutes →

PRs that pass CI individually can break main when merged together. Mergify updates each PR against the latest main and re-runs CI before merging—catching conflicts before they hit production.

How the queue works

Serial testing creates bottlenecks. Mergify tests multiple PRs in parallel using speculative execution, so your queue moves as fast as your CI allows.

Parallel checks

Running full test suites on every PR is expensive. Mergify batches PRs together into single CI runs and supports two-step CI to run heavy tests only at merge time.

Batches | Two-step CI

Unrelated changes shouldn’t block each other. Mergify uses scopes to identify which services a PR affects and only batches compatible changes together.

Scopes | Monorepo guide

FeatureWhat it does
Parallel checksTest multiple PRs simultaneously
BatchesCombine PRs into single CI runs
Priority rulesLet urgent PRs jump the queue
Two-step CIRun heavy tests only at merge time
ScopesSmart batching for monorepos
Queue rulesRoute PRs to different queues
PauseFreeze merges during incidents