Last update: 2025-11-10T14:09:43.000Z
Content:
---
title: "Branches · Tinybird Docs"
theme-color: "#171612"
description: "Create branches from your production workspace to develop and test your project before deploying to production."
inkeep:version: "forward"
---




# Branches (Beta) [¶](https://www.tinybird.co/docs/forward/test-and-deploy/branches#branches-beta)

Copy as MD Tinybird branches allow you to develop and test your project in ephemeral environments using production data.

Branches are currently in beta. Some features might not be available yet or might change in the future.

## Create a branch [¶](https://www.tinybird.co/docs/forward/test-and-deploy/branches#create-a-branch)

tb branch create preview_1 If you want to use production data, you can use the `--last-partition` flag yo bring the last partition of the production data into the branch.

tb branch create preview_1 --last-partition
## Start branch [¶](https://www.tinybird.co/docs/forward/test-and-deploy/branches#start-branch)

tb --branch=preview_1 dev Keep this terminal running while you are working in the branch.

`tb dev` will watch for changes in your project and rebuild it automatically.

» Building project...
✓ datasources/user_actions.datasource created
✓ endpoints/user_actions_line_chart.pipe created
✓ Rebuild completed in 0.2s If you stop the process with `Ctrl+C` , you will stop the branch.

» Received shutdown signal, stopping...
✓ Branch 'preview_1' session stopped
## Make changes to your project [¶](https://www.tinybird.co/docs/forward/test-and-deploy/branches#make-changes-to-your-project)

While `tb --branch=preview_1 dev` is running, you can edit files in your project and see the changes automatically applied in your branch.

### Using your editor [¶](https://www.tinybird.co/docs/forward/test-and-deploy/branches#using-your-editor)

Open your editor of choice and start editing your project. The branch will automatically detect the change and rebuild your project:

» Building project...
✓ datasources/user_actions.datasource updated
✓ Rebuild completed in 0.3s
### Using Tinybird UI [¶](https://www.tinybird.co/docs/forward/test-and-deploy/branches#using-tinybird-ui)

You can also use Tinybird UI to edit your project. Run the following command to open the Tinybird UI pointing to your branch.

tb --branch=preview_1 open `tb dev` exposes your project as API, so you can edit it directly in the browser and see changes applied automatically.

## When to use branches [¶](https://www.tinybird.co/docs/forward/test-and-deploy/branches#when-to-use-branches)

Branches are a great way to test your project with real production data. You should use them in the following scenarios:

- You want to test your changes with real production data.
- You work with preview environments in your CI/CD pipeline before deploying to production.
- You don't use Docker and you want to test your changes without affecting production.


