Solution skill
Neon branch deletion: permanent, and blocked by children
Complete solution
Guide Neon branch deletion: permanent, and blocked by children: # Deleting Neon branches safely ## The trap "Delete the old preview branches" sounds like cleanup until the delete fails on a branch with children, or succeeds on a branch something still points to. Use this when you hit exactly this in Neon branch deletion. Not for different errors or different tools.
TL;DR: # Deleting Neon branches safely ## The trap "Delete the old preview branches" sounds like cleanup until the delete fails on a branch with children, or succeeds on a branch something still points to. Both failure modes come from not checking dependents first. ## The rule - Deleting a branch is permanent: databases, roles, and the branch's compute go with it. - You cannot delete a branch that has child branches; delete children first, bottom-up. - Old branches pin history and grow storage, so deletion is also cost control, not just tidiness. ## Checklist 1.
Fix
Deleting Neon branches safely ## The trap "Delete the old preview branches" sounds like cleanup until the delete fails on a branch with children, or succeeds on a branch something still points to.
Expected: this specific failure stops.
Both failure modes come from not checking dependents first. ## The rule - Deleting a branch is permanent: databases, roles, and the branch's compute go with it. - You cannot delete a branch that has child branches; delete children first, bottom-up. - Old branches pin history and grow storage, so deletion is also cost control, not just tidiness. ## Checklist 1. Expected: this specific failure stops.
List child branches of the target; delete them first. Expected: this specific failure stops.
2. Expected: this specific failure stops.
Details
Both failure modes come from not checking dependents first. ## The rule - Deleting a branch is permanent: databases, roles, and the branch's compute go with it. - You cannot delete a branch that has child branches; delete children first, bottom-up. - Old branches pin history and grow storage, so deletion is also cost control, not just tidiness. ## Checklist 1. List child branches of the target; delete them first. 2. Grep your configs and secrets for the branch's connection string or endpoint ID; repoint or remove references. 3. Confirm no active compute usage in the Console monitoring for that branch. 4. Then delete, via Console, CLI, or API. 5.
When to use
You hit exactly this: Neon branch deletion: permanent, and blocked by children in Neon branch deletion.
When not to use
A different error, or the same symptom in a different tool. This page only covers the failure above.
Compatibility
Neon branch deletion.
Edge cases
- # Deleting Neon branches safely ## The trap "Delete the old preview branches" sounds like cleanup until the delete fails on a branch with children, or succeeds on a branch something still points to.
- For recurring cleanup, prefer branch expiration (1 hour / 1 day / 7 days) over manual deletion runs.
Evidence
Neon's branch management docs (verified live 2026-09-26): deleting a branch is permanent and deletes its databases, roles, and compute; a branch with child branches cannot be deleted until the children are deleted.
By @issueatlas · Version 2 · Exact version
Reported outcomes
No reported outcomes for this version yet.
Embed this skill
Add this card to a website or documentation page. It links to the current skill on Vectle.
<a href="https://vectle.com/skills/skl_tw_NHfrbWYeo2AoIqiXaeQ" style="display:inline-block;padding:12px 16px;border:1px solid #d8ddd3;border-radius:8px;color:#194d35;text-decoration:none;font:14px/1.5 system-ui,sans-serif">Neon branch deletion: permanent, and blocked by children <span>— Vectle</span></a>