> ## Documentation Index
> Fetch the complete documentation index at: https://bilanc.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# Pull Request Exclusion Rules

> Exclude noisy pull requests from analytics, and the git logic behind each rule

Exclusion rules remove specific pull requests from PR analytics — release-train merges, environment-promotion PRs, automated sync PRs, bot branches, and other noise that would otherwise inflate throughput and distort cycle time. Rules are per organization and don't delete data; disabling or deleting one restores the affected PRs on the next refresh.

In the dashboard, open the PR exclusion rules settings and choose **Add rule**.

## How rules work

A rule describes the pull requests to **throw away** — a PR that matches an enabled rule is dropped. There's no "keep only these" mode; to keep a narrow set, exclude everything that isn't in it using the negated match types.

* **Within a rule**, the conditions (repositories, source branch, target branch, title) are AND-ed — a PR matches only if it satisfies all of them.
* **Across rules**, matching *any* enabled rule is enough to exclude a PR. Add more rules to exclude more things.

## Git terminology: source vs target

A PR always flows **source → target**.

| Field               | Git concept | Column        | What it is                                               |
| ------------------- | ----------- | ------------- | -------------------------------------------------------- |
| **Source branches** | `head`      | `branch_name` | The branch merging **from** — the feature/topic branch.  |
| **Target branches** | `base`      | `base_ref`    | The branch merging **into** — e.g. `main`, `production`. |

<Warning>
  `base_ref` is the **target** branch, not the source. In git PR terms, `base` is the branch you merge *into*. "Exclude PRs that go into production" is a **Target branch** condition.
</Warning>

The mapping is the same across GitHub, GitLab, Bitbucket, and Azure DevOps.

## Conditions and match types

**Repositories** has no match type — listed repos scope the rule to those repos; empty means all repos. The other three fields take a list of values (comma- or newline-separated) plus a match type. Matching is always case-insensitive. Leaving a field blank ignores it.

| Match type     | Meaning                                     |
| -------------- | ------------------------------------------- |
| **Equal**      | Field equals one of the listed values       |
| **Prefix**     | Field starts with one of the listed values  |
| **Not equal**  | Field equals none of the listed values      |
| **Not prefix** | Field starts with none of the listed values |

The negated types are how you express "keep only X": *exclude every PR whose target branch is not `production`* keeps exactly the production-targeting PRs.

## Example: keep only one target branch in one repo

Goal: in one repository, keep only PRs merging into `production` and exclude everything else, leaving all other repositories untouched.

| Field           | Value        | Match type    |
| --------------- | ------------ | ------------- |
| Repositories    | *(the repo)* | —             |
| Target branches | `production` | **Not equal** |

This excludes any PR in that repo whose target branch isn't `production`. Because the repository is scoped, no other repo is affected.

<Warning>
  Don't use **Equal** here — that would drop the production PRs you want to keep. The negation (`production` + **Not equal**) is correct.
</Warning>

## Common patterns

Each row is one rule. Conditions within a rule are AND-ed — to exclude on either of two conditions independently, create two rules.

| Goal                                                        | Repositories | Source                              | Target                        | Title                 |
| ----------------------------------------------------------- | ------------ | ----------------------------------- | ----------------------------- | --------------------- |
| Drop release-train merges into `main`                       | *(all)*      | —                                   | `main` **Equal**              | `release:` **Prefix** |
| Exclude everything except work merging into `main`/`master` | *(scoped)*   | —                                   | `main, master` **Not prefix** | —                     |
| Drop bot/automation branches                                | *(all)*      | `dependabot/, renovate/` **Prefix** | —                             | —                     |

<Note>
  Rules apply only to enabled rows and take effect on the next analytics refresh. They don't modify underlying data.
</Note>
