Skip to content

Branch environments

A branch environment is a complete, isolated copy of your site that managed.dev provisions when you push a branch. It has its own database and files — seeded from production — its own hostname and TLS, and its own observability. You get them on every plan, not just an enterprise tier.

The model is deliberately simple: a git branch maps to an environment, and the environment is the unit you deploy, preview, snapshot, and promote. Push main and you deploy production. Push feature/checkout and you get a preview you can hand to a reviewer.

managed.dev recognizes three tiers, distinguished by how they’re created and how long they live.

Tier Mapped from Lifetime Seeded from
production the default branch (main) permanent the live site
staging a branch route → staging long-lived, singleton production
preview any non-default branch ephemeral, per-branch production

Production is the live site your visitors hit. Staging is a single, stable pre-production environment you promote into. Previews are throwaway: one per branch, created on push and torn down when the branch is deleted. You decide which branch lands where with branch routes.

An environment is not a configuration flag on your site — it’s a real resource with its own state.

Own database + files

Each environment has an isolated database and filesystem, cloned from production at create time. A migration you run on a preview can’t touch production data.

Own observability

Per-environment web vitals, logs, and traces. A slow query on staging shows up under staging, not muddled into production.

Own hostname + TLS

Every environment gets a live URL with automatic TLS. Production carries your custom domain; previews and staging get platform hostnames.

Config inheritance

Environments inherit configuration from the site — security tier, performance tier, secrets — and you override per-environment where you need to.

Each environment is reachable on a hostname under a per-node label, following the convention <env>.<node-label>.<zone>. Preview environments additionally get a disposable URL built from the site, branch, and a short hash:

Preview URL pattern
https://<site>-<branch>-<hash>.preview.managed.dev

For example, a push of feature/checkout on the acme-store site provisions something like https://acme-store-feature-checkout-a1b2c3.preview.managed.dev. The hash keeps the URL stable for the branch but distinct from any other site, so it’s safe to paste into a pull request or send to a client.

The Environments tab in the app.managed.dev dashboard for the acme-store site, showing a production environment plus a staging environment and two preview environments, each with a status badge, branch name, and live preview URL.

Isolation is the whole point. A branch environment cannot read or write production’s database or files, and the reverse holds too. Builds run on a dedicated builders pool, never on the host serving your live site, so a heavy build can’t degrade production.