> Switchyard: the page at https://switchyard.so/compare/trunk as markdown. Every page is listed at https://switchyard.so/llms.txt

Compare

# Switchyard and Trunk Merge Queue

Trunk Merge Queue is a merge queue for pull requests, from a company that says it formed in 2021. Switchyard is new, and starts earlier in the work: with each agent's task, before a pull request exists. This page says what each does, when Trunk is the better choice, and when Switchyard is.

Checked on 24 November 2026. Every claim about Trunk links Trunk's own documentation, pricing page or about page.

## Trunk Merge Queue

It tests each pull request against the head of main plus every pull request ahead of it, runs unrelated pull requests in independent test lanes, keeps merging when a flaky test would stall the queue, and can test pull requests in batches. [Trunk: merge queue overview](https://docs.trunk.io/merge-queue/merge-queue).

## Switchyard

It gives each coding agent its own task, warns two tasks when their work overlaps while they are still working, tests submitted tasks together in a merge queue, and merges them on main when the checks pass and the rules allow. [Introduction](/docs/introduction).

## What the two have in common

- Both test queued changes with main and the changes ahead of them, so what merges is what was tested.
- Both can test several changes in one run, and both find the change that caused a failed batch.
- Both give a failure a second look before a change is taken out, so that a flaky test does not send good work back.
- Both have a way to put urgent work ahead, and both handle changes stacked on each other.
- Both work on GitHub through a GitHub App installed on the repository.

## Side by side

| What | Trunk Merge Queue | Switchyard |
|---|---|---|
| Code hosts | GitHub, through the Trunk GitHub App. It also works with merge requests on GitLab.com, which Trunk marks as beta; self-managed GitLab is not supported yet. [Trunk: GitLab](https://docs.trunk.io/merge-queue/getting-started/gitlab). | A GitHub repository, or a repository hosted by Switchyard. A repository on GitLab, Bitbucket or another Git host can be imported once and then lives in Switchyard. [Import, move off GitHub and export](/docs/ways-in-and-out). |
| Where it starts | At a pull request. Trunk waits until GitHub considers the pull request ready to merge, by your branch protection rules, before testing begins. [Trunk: configure CI status checks](https://docs.trunk.io/merge-queue/getting-started/configure-ci-status-checks). | Before a pull request exists. An agent starts a task and writes a plan of the paths, symbols and interfaces it expects to change. A pull request is optional: one with the label `switchyard` goes through the merge queue like a task. [Pull requests in the merge queue](/docs/pull-requests). |
| When two changes overlap | In parallel mode each pull request reports its impacted targets, and a pull request that shares targets with ones ahead of it is tested with their changes. [Trunk: parallel queues](https://docs.trunk.io/merge-queue/optimizations/parallel-queues). | Both tasks are told while they work, from their plans and from pushed code. Warnings about symbols and dependencies cover six languages; other files get warnings about overlapping lines. Each warning has one suggestion. [Tradeoffs](/docs/tradeoffs#code-aware-warnings-cover-six-languages). |
| What one run tests | One pull request with the pull requests ahead of it, unless batching is on. Batching is off by default; its starting values are a target batch size of 4 and a maximum wait of 5 minutes. [Trunk: batching](https://docs.trunk.io/merge-queue/optimizations/batching). | A batch: main plus up to 32 submitted tasks, in order, as one test build. Switchyard chooses the number from how recent batches went and how many tasks wait. [Limits](/docs/limits#checks-and-the-merge-queue). |
| Runs at the same time | Testing concurrency caps how many pull requests test at once: 5, 25, 50 or a custom number. [Trunk: settings and configurations](https://docs.trunk.io/merge-queue/administration/advanced-settings). | One batch at a time on a project that follows a GitHub repository. Up to 20 batches, 16 unless you set it, only on a project hosted by Switchyard, made since 19 November 2026, with its checks on Switchyard's machines. [Write rules and checks](/docs/rules#share-the-merge-queue-fairly). |
| When a test fails | A failed pull request waits in a pending failure state for the pull requests ahead of it, so that the queue removes only the first faulty one and tests the others again without it. A batch that fails is split apart to find the pull request that caused the failure. [Trunk: predictive testing](https://docs.trunk.io/merge-queue/optimizations/predictive-testing) and [Trunk: batching](https://docs.trunk.io/merge-queue/optimizations/batching). | A failed check runs once more before any task is blamed. If it fails again, the merge queue finds the task that caused the failure and sends back that task only, with the reason; the other tasks stay in the merge queue. The extra runs are billed. [How a task reaches main](/docs/task-lifecycle#what-sent-back-means). |
| Flaky tests | Anti-flake protection combines optimistic merging and pending failure depth to merge pull requests that would otherwise be rejected from the queue. Trunk Flaky Tests, another Trunk product, detects, tracks and quarantines flaky tests. [Trunk: anti-flake protection](https://docs.trunk.io/merge-queue/optimizations/anti-flake-protection) and [Trunk: Flaky Tests](https://docs.trunk.io/flaky-tests/overview). | The one more run before any task is blamed. A check that failed and then passed on the same tree is counted as a flaky check caught, in the project's value. Switchyard has no quarantine. [Concepts](/docs/concepts#value). |
| Monorepos | Parallel queues: pull requests that affect distinct impacted targets are tested in lanes of their own. Trunk ships ways to post impacted targets for Bazel and Nx, and an API for other build systems. [Trunk: parallel queues](https://docs.trunk.io/merge-queue/optimizations/parallel-queues). | Merge trains test and land tasks that touch nothing in common apart, so one does not wait for another. They are a project setting that is off by default. [Concepts](/docs/concepts#merge-queue). |
| Conflicts | A merge conflict is among the reasons a pull request fails in the queue, and a pull request that fails is removed so that it does not block the others. [Trunk: handle failed pull requests](https://docs.trunk.io/merge-queue/using-the-queue/handle-failed-pull-requests). | Five steps try to fix the conflict, in order: Git merge, file rules, code rules, an AI suggestion unless the organization turned AI fixes off, then a person. A fix the file rules wrote, or a suggestion an agent accepted, waits for a person's approval unless the project lets fixes merge without one. A task whose conflict stays is sent back. [Fix a conflict](/docs/conflicts). |
| Where checks run | On your own CI. By default Trunk creates draft pull requests to test changes, and your pull request workflows run on them. Trunk Runners run GitHub Actions jobs on Trunk's machines, from $0.006 a minute for the default machine; Trunk says they are in a beta that you ask to join. [Trunk: configure CI status checks](https://docs.trunk.io/merge-queue/getting-started/configure-ci-status-checks), [Trunk: Runners](https://docs.trunk.io/runners) and [Trunk: Runners pricing](https://docs.trunk.io/runners/pricing). | On Switchyard's machines: a new machine for each check, with no secrets, billed per second, minimum one minute per job, at $0.005 a minute small and $0.02 large. Or on your own GitHub Actions, which Switchyard waits for. A job labelled `runs-on: switchyard` runs on a Switchyard machine; today those runners take the jobs of Switchyard's own test builds. [Write rules and checks](/docs/rules#use-tests-on-github-actions). |
| Price | Free for teams of up to 5 committers, and no credit card to start. Team is a paid plan with a free trial, and Enterprise is priced on request. [Trunk: pricing](https://trunk.io/pricing). | From $20 a month on Launch: each month you pay the larger of the plan's minimum and your usage. Every plan has a minimum. The first week is $1, and the card is taken before work starts. Agents, tasks, merges and people are not metered. [Pricing](/pricing). |
| Record | Trunk's about page says the company formed in 2021, and its pricing page shows customer stories. [Trunk: about](https://trunk.io/about) and [Trunk: pricing](https://trunk.io/pricing). | The service is new: sign-up opened on 20 November 2026. [Terms](/terms). |

## Choose Trunk when

- Your work is pull requests, and the merge is the only step you want to change.
- You want a mature product: Trunk says it formed in 2021 and shows customer stories. Switchyard is new.
- You want to start free. Trunk is free for teams of up to 5 committers and asks for no credit card to start. Switchyard takes a card first.
- You have a monorepo on Bazel or Nx and want the build graph to decide which pull requests are tested apart.
- Flaky tests are what stalls your queue, and you want them detected and quarantined. Switchyard runs a failed check once more and has no quarantine.
- You want many pull requests tested at once on your own CI. On a project that follows a GitHub repository, Switchyard tests one batch at a time.
- Your code is on GitLab.com: Trunk works with merge requests there, in beta. Switchyard does not follow a GitLab repository.

## Choose Switchyard when

- Several agents work on one repository and collide before any pull request exists. Tasks, plans and warnings are for that stage.
- You want batches without setting them up: the merge queue tests up to 32 tasks as one build and chooses the number itself.
- You want the merge queue to run the checks itself, on machines billed by the second, and to reuse a pass on the same code.
- A conflicted change should go through fixing steps, with an AI suggestion unless you turn it off, before it goes back to its agent or to a person.
- You want a repository that Switchyard hosts, with no GitHub behind it, or work that goes on while GitHub does not answer.
- Your agents should do the work themselves, through plain Git, the yard CLI, MCP or the REST API.

## Why we built it this way

Switchyard was built for one case: several coding agents changing one repository at the same time. Each choice below follows from that case, and each has a cost that this page names.

### One build for a batch

Agents submit many small changes close together, so the merge queue tests main plus up to 32 submitted tasks as one build. When the build passes, one run of the checks has covered all of them. When it fails, the failed check runs once more, the task that broke the batch is found and sent back, and those extra runs are billed. A batch saves check time only while most batches pass. The [limits](/docs/limits#checks-and-the-merge-queue) page has the numbers.

### Warnings before a pull request

Two agents can start on the same function minutes apart. If the first check comes at the merge, both have already done the work. So each task says what it will touch in a plan, Switchyard merges main with every active task again as tasks push, and both tasks hear about an overlap while they are still working, each with one suggestion. [Concepts](/docs/concepts#warning) defines a plan, a warning and the merge preview.

### Checks on our machines

A test build is a commit the merge queue makes, main plus the batch, so the queue needs somewhere to run the checks on it. Switchyard can run them itself: each check on a new machine, with the test build checked out and no credential from Switchyard, billed for the time its command runs. Because it keeps each result by the content of the tree, a tree that already passed is not run again. A check can wait for your own GitHub Actions instead, and then you pay your CI provider and not Switchyard. [Write rules and checks](/docs/rules#use-tests-on-github-actions) has both ways.

### Its own Git store

Every task is its own copy of the repository, and a push's commits are stored before Git is told that the push succeeded. Switchyard keeps them in a Git store of its own, one for each project, so tasks keep pushing, planning and being tested while GitHub does not answer; merges on a followed repository wait until it does. The cost is a second copy of your code with a new company. On a project that follows a GitHub repository, GitHub still holds main. The [architecture](/docs/architecture#your-code) page says how it is kept.

## Sources

Checked on 24 November 2026. Products change: if a line here is out of date, [tell us](/contact). We have not measured Switchyard against Trunk Merge Queue, so this page makes no claim about which is faster.

- [Trunk Docs: merge queue overview](https://docs.trunk.io/merge-queue/merge-queue), [predictive testing](https://docs.trunk.io/merge-queue/optimizations/predictive-testing), [batching](https://docs.trunk.io/merge-queue/optimizations/batching), [parallel queues](https://docs.trunk.io/merge-queue/optimizations/parallel-queues), [anti-flake protection](https://docs.trunk.io/merge-queue/optimizations/anti-flake-protection), [priority merging](https://docs.trunk.io/merge-queue/optimizations/priority-merging) and [stacked pull requests](https://docs.trunk.io/merge-queue/using-the-queue/stacked-pull-requests)
- [Trunk Docs: install and create your queue](https://docs.trunk.io/merge-queue/getting-started/install-and-create-your-queue), [configure CI status checks](https://docs.trunk.io/merge-queue/getting-started/configure-ci-status-checks), [GitLab](https://docs.trunk.io/merge-queue/getting-started/gitlab), [settings and configurations](https://docs.trunk.io/merge-queue/administration/advanced-settings) and [handle failed pull requests](https://docs.trunk.io/merge-queue/using-the-queue/handle-failed-pull-requests)
- [Trunk Docs: Flaky Tests](https://docs.trunk.io/flaky-tests/overview), [Runners](https://docs.trunk.io/runners) and [Runners pricing](https://docs.trunk.io/runners/pricing)
- [Trunk: pricing](https://trunk.io/pricing) and [Trunk: about](https://trunk.io/about)
- [Switchyard docs](/docs/introduction) and [pricing](/pricing), for every line about Switchyard
