Keep the project’s main data branch as the default branch
Production baseline
Neon · Const
In current Neon terminology, “primary branch” is called the project’s default branch. It is the root branch created with each project and serves as the normal origin for new branches.
Neon’s current documentation uses “default branch” for the branch historically called the primary branch. Each project has one root branch that is also its default branch; it is the starting point for child branches and cannot be deleted.
production, whereas API and CLI projects use main.neon branches list --project-id "$NEON_PROJECT_ID"Lists the project's branches; use the branch designated as the default branch for the project's main database workflow.
Production baseline
Development isolation
Feature or preview environments
Neon’s current term is default branch rather than primary branch. It is the project’s root branch, and every project starts with one.
Follow-up: How do you identify it in different creation paths? Console-created projects use production; API- or CLI-created projects use main.
A child branch is created from a selected existing branch. If no parent is specified, Neon uses the project’s default branch, so it supplies the normal starting point for new branches.
Follow-up: Can a child branch be based on another child? Yes; Neon allows branching from the default branch or any existing branch.
The root branch is also the project’s default branch and cannot be deleted. Its schema and data provide the baseline from which other branches can be created.
Follow-up: What changes if you select another parent? The new branch derives its schema and data from that selected existing branch instead of directly from the default branch.
default branchroot branchchild branchparent branchbranching