With two developers, branch names do not matter - you both know what everything is. Add a third, then a fifth, and suddenly fix-stuff and stefan-wip-2 are a shared inbox full of unmarked letters. A naming convention is not bureaucracy; it is how a branch list becomes readable at a glance.
The shape that works#
BILL-88-retry-failed-invoices
feature/team-invitations
hotfix/checkout-double-charge
Three ingredients, in rough order of value:
- A ticket reference when one exists.
BILL-88-retry-failed-invoiceslinks the branch to the tracker without opening anything. Tools pick this up automatically - GitHub and GitLab cross-reference, and the PR inherits the link. When there is no ticket, skip it; inventing ceremony for a typo fix is worse than omitting it. - Lowercase words joined by dashes. No underscores, no camelCase, no spaces escaped into
%20. Branch names appear in URLs, CI logs and shell commands; the boring format survives all three. - A type prefix for the exceptions.
hotfix/andrelease/prefixes earn their keep because they signal urgency and different rules - a hotfix skips the queue (see shipping a hotfix without the drama). Feature branches need no prefix; they are the default case.
The conventions that collapse#
Names as ownership. stefan-billing tells you who, not what - and the moment two people touch it, the name is a lie. Ownership lives in the PR assignee, not the branch.
Version branches that never die. v2-redesign living for four months is not a branch, it is a fork with anxiety. If work takes that long, the answer is feature flags and incremental merges, not a longer-lived branch name.
Over-specified formats. type/TEAM-1234/short-description/v1 looks great in a wiki and collapses on contact with reality. Every required element is a place to be wrong.
Pair it with cleanup#
Names decay faster than branches. A convention only stays legible if merged branches get deleted - most hosts offer this as a button or an automatic setting - and stale ones get pruned locally (git fetch --prune, or the config version in five git config settings worth changing). A branch list of twelve current names beats a list of two hundred historical ones, whatever convention they follow.
Pick the boring format, write it in CONTRIBUTING.md, and spend the saved energy on the work the branches exist for.
Share this post
Keep reading
A First CI Pipeline for a Laravel Project
Install, lint, test, build - four jobs that run on every pull request and turn 'works on my machine' into a check everyone can see.
A Staging Environment Worth Having
Staging only catches what it shares with production. Same deploy path, same services, sanitized data - and a clear rule for what it is for.
Branch Protection Rules That Stick
Three rules cover most of the risk on main: review required, tests green, no force-push. More than that tends to get routed around.