ZEKTOR.IO Docs

Branching

Branches are isolated database deployments that provide separate environments for development, testing, and restoring from backups.

Overview

Branches on Zektor.io PostgreSQL are isolated database deployments that provide you with separate environments for development and testing, as well as restoring from backups.

Every PostgreSQL database starts with a default main branch. You can create additional branches from backups for testing, development, or disaster recovery.

How Branching Works

When you create a branch, Zektor.io provisions a new, independent database instance that contains a copy of your data from a specific point in time. Each branch:

  • Has its own connection credentials
  • Runs on its own compute resources
  • Can be independently scaled
  • Is billed separately based on the cluster size you choose

Creating a Branch

From the Branches Page

  1. Navigate to your instance's Branches tab
  2. Click New Branch
  3. Provide a name for the branch
  4. Select a cluster size
  5. Click Create Branch

From a Backup

You can also create a branch by restoring from a backup:

  1. Navigate to your instance's Backups tab
  2. Find the backup you want to restore
  3. Click Restore on the backup entry
  4. Provide a branch name and select a cluster size
  5. Click Restore

This creates a new branch with all data as of the backup's point in time.

From Point-in-Time Recovery (PITR)

PITR lets you restore to any specific timestamp:

  1. Navigate to your instance's Backups tab
  2. Click Restore Backup
  3. Select the exact date and time to restore to
  4. Choose a cluster size and optionally set a branch name
  5. Click Restore

Note: The target restore time must be at least 2 minutes in the past.

Viewing Branches

All branches for a database instance are visible in the Branches tab. For each branch, you can see:

  • Name — The branch identifier
  • Status — Active, Provisioning, or Stopped
  • Cluster size — The compute tier
  • Created — When the branch was created

Connecting to a Branch

Each branch has its own set of connection credentials. Navigate to a branch's Settings tab to find:

  • Host and port
  • Username and password
  • Connection string

See Connecting for detailed instructions on using these credentials with your preferred client or ORM.

Deleting a Branch

  1. Navigate to the Branches tab
  2. Select the branch you want to delete
  3. Click Delete Branch in the branch settings

Warning: Deleting a branch permanently removes the database and all its data. This action cannot be undone.

You cannot delete the default main branch.

Branch Behavior

  • Branches are independent — Changes made to a branch do not affect the source database or any other branch
  • Schema changes — Each branch maintains its own schema. Changes made on one branch are not applied to others
  • Extensions — PostgreSQL extensions may need to be reinstalled on restored branches
  • No automatic sync — Branches do not receive updates from the main branch after creation. They are a snapshot from the point of creation.

Use Cases

Use CaseDescriptionRecommended Tier
Disaster RecoveryRestore from a backup to verify your data is intactSame as production
Testing MigrationsTest schema changes against real data before applying to productionStarter or Standard
DevelopmentWork on schema changes without affecting productionStarter
Data AnalysisRun expensive queries on a branch to avoid impacting productionStandard or Pro
Pre-release ValidationValidate application code against a copy of production dataSame as production

Tip: Use a smaller (cheaper) cluster size for development and testing branches. You can always scale up if needed.

Next Steps

  • Backups & PITR — Learn about backup schedules and point-in-time recovery
  • Connecting — Connect to your branch
  • Scaling — Resize a branch's cluster
  • Pricing — Understand branch billing

On this page