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

# The Branch page

> Create, compare, apply, rebase and discard a branch from the Bijection console

<Warning>Branches are in beta.</Warning>

You can work with branches from the Bijection console as well as from the
[command line](/branches/cli).

Branches work the same on a deployment's pages at
[console.bijection.com](https://console.bijection.com) and in the console you
sign in to with a deployment URL and admin key. On console.bijection.com the
console uses your sign-in, so you need no admin key.

## Branching from live

On a deployment that is not itself a branch, the console header has a **Branch
from live** button. Enter a branch name (lowercase letters, digits and
hyphens) and click **Create branch**.

The console forks live at its current revision with the default lifetime of 3
days, and switches to the new branch. From then on, every console page, such
as [Data](/dashboard/deployments/data) or
[Functions](/dashboard/deployments/functions), shows the branch.

On console.bijection.com, the branch stays open in that browser tab for that
deployment, including after a reload, until you click **Return to live** in
the branch banner. Other tabs, and other deployments, stay on live.

## The branch banner

While the console is on a branch, a banner on every page names the branch and
reminds you that external calls are held. When the console holds credentials
for the parent, as it always does on console.bijection.com, the banner also
says what the branch is a fork of and as of when,
when it expires or whether it was discarded, and how far it was applied to
live. Click the branch name to open the Branch page. On console.bijection.com,
the banner also has **Return to live**.

## The Branch page

The **Branch** item in the sidebar appears only on a branch. The page has four
sections.

On console.bijection.com, **Releases** and **History** leave the sidebar while
a branch is open, because they act on the deployment itself rather than the
branch. Return to live to use them.

<Info>
  Lifecycle actions run on the parent deployment, which refuses the branch's own
  admin key. On console.bijection.com they use your sign-in. In the console you
  sign in to with an admin key, the console already holds the parent's admin
  key for the tab when you created the branch from it. Otherwise, enter it
  under **Parent admin key** and click **Use key**. **Forget** removes it.
</Info>

### Summary

The summary shows:

* **Parent**: live or an empty deployment, and the parent's URL.
* **Forked at**: the branch's basis.
* **State**: open with its expiry, expired, or discarded.
* **Applied to live**: how far operations were applied, and when last.
* **Owner**.
* **Link**: a new, personal [branch link](/branches/lifecycle#opening-a-branch)
  to copy, and **Open with this link**.
* **Shared with**: each user the branch is shared with, with **Unshare**.

Below it, on an open branch:

* **Expire in (hours)** and **Extend** set a new expiry from now.
* **Share with user** and **Share** admit a user by token identifier
  (`issuer|subject`), not a JWT.
* **Discard branch** asks you to type the branch key to confirm. Everything
  committed on the branch is deleted, and its links stop working. What was
  already applied to live stays applied.

### Compare

Enter a query path, such as `items:list`, and its arguments, then click
**Compare**. The console runs the query on the branch and on live at the
branch's basis, and shows the documents added, removed and changed, with a
field-by-field table for each changed document. It also says how far live has
moved past the basis.

### Apply to live

Click **Preview** to see what [applying](/branches/apply-and-rebase) would do.
**Apply to live** is enabled only when the preview has something to apply and
no step was refused or diverged. It asks you to confirm, then commits.

The report lists each step with its status, the documents whose IDs were
remapped, anything that waits for a later apply, and branch changes that
replay does not carry.

### Rebase

On an open branch of live, enter a new branch name and click **Rebase**. The
console replays your operations onto a fresh fork of live under that name,
shows the replay report, and gives you the new branch's link and admin key.
This branch is kept.

<Note>
  The Branch page acts as the administrator whose key it holds, or on
  console.bijection.com as your signed-in account's administrator identity,
  not as one of your app's users. Apply and rebase replay the operations
  invoked by that identity. To apply operations you ran as a user, use
  [`bijection branch apply --identity`](/branches/cli#bijection-branch-apply).
</Note>
