Guide

Progressive delivery with feature flags

Release to a few users first, watch what happens, and widen the audience step by step. Here are the stages, how it differs from a canary deployment, and what to watch before moving on.

Progressive delivery means releasing a change to a small share of users first, watching what happens, and widening the audience step by step, with a way to go back at every step. Feature flags are the usual mechanism, because they change who sees a feature without a new deploy.

Why release gradually

Staging never behaves exactly like production: real data, real traffic patterns and real devices find problems tests don't. Releasing to everyone at once means the first time you learn about such a problem is when every user has it. A gradual release limits the damage to the share you have exposed, and gives you time to notice.

The stages of a gradual rollout

  1. Internal users. Target your own team with a rule on email domain or a segment. Dogfooding catches the obvious problems for free.
  2. Beta customers. Add a segment of customers who opted in. They expect rough edges and give feedback.
  3. A small percentage. 1 to 5 percent of everyone, chosen by a hash of the user id, so the same users stay in the group as you widen it.
  4. Widening steps. 10, 25, 50, 100 percent, with a pause at each step long enough to see the effect. The right pause depends on traffic: you need enough users in the group for a problem to show up.
  5. Cleanup. At 100 percent for long enough, delete the flag and the old code path. See feature flag cleanup.
5%10%25% 50%100% team only beta customers hold 1 hour not reached not reached ! Release Watch checks the limit before each step error rate over the limit rollout paused at 25%
The pause happens before the next widening, not after the damage. Each green gate is a check against the limit you set; the orange one stops the rollout until a person decides.

Canary deployments vs feature flags

Compared onCanary deploymentFeature flag rollout
What is splitTraffic between two versions of the codeUsers between two behaviours in one version
Chosen byThe load balancer or mesh, often per requestYour code, per user, with targeting rules
RollbackShift traffic back or redeploySet the flag off, effective in seconds
Same user, same experienceNot guaranteedYes, with consistent bucketing
Best forInfrastructure and runtime changesProduct behaviour and user-visible features

They combine well: canary the deploy to prove the new build is healthy, then use flags to release features inside it. Trunk-based development relies on exactly this split between deploying and releasing.

Consistent bucketing keeps users in their group

A percentage rollout hashes a stable id, typically the user id combined with the flag key, into one of 100,000 buckets. A user in bucket 12,000 is inside the 20 percent rollout (buckets 0 to 19,999) and stays inside it at 30, 50 and 100 percent. Without that, widening from 10 to 20 percent would reshuffle who sees the feature and users would flip between the old and new experience. It also means that choosing the targeting key matters: use a stable id, not a session id that changes on every visit. The feature flags guide shows the arithmetic.

What to watch at each step

  • Errors and latency in the exposed group compared with everyone else, not only overall. A problem in 5 percent of users barely moves an overall graph.
  • Business metrics that the change could affect: sign-up completion, checkout conversion, search usage.
  • The rollout itself. Is the share of users getting the new variation what you set? A mismatch usually means a context without a stable targeting key or a caching layer in front.
  • Support signals: tickets and chat mentions from the exposed group.

Doing this by hand means someone has to remember to look. Release Watch suggests what to monitor before a Production change, watches your monitoring tool during the rollout, checks that the rollout really reaches the share you set, and can pause it when a limit is crossed.

Make rollback a one-click decision

The point of going gradually is that going back is cheap. Decide the rollback rule in advance: "error rate in the exposed group above X for Y minutes", not "if it looks bad". Keep the off path working and tested (see testing code behind flags), and keep the flag in place until you are done, because a rollback with a flag is a toggle and without one is a deploy. For a risky dependency, a permanent kill switch stays after the rollout finishes.

Rollout or experiment?

A rollout asks "is it safe to release?" and aims at 100 percent. An experiment asks "does it work better?" and holds a split steady until there is enough data to decide. The mechanics are the same, a flag with a percentage split, so many teams start with a rollout and turn the split into an experiment when they also want a measured result.

Frequently asked questions

What is progressive delivery?

Progressive delivery is releasing a change to a growing share of users in stages, for example internal users, then 5 percent, then 25 percent, then everyone, while watching metrics and keeping a fast way to go back. Feature flags are the usual mechanism.

What is the difference between progressive delivery and a canary deployment?

A canary deployment splits traffic between two versions of the code, usually at the load balancer. A flag-based rollout splits users between two behaviours inside one version, per user and with targeting rules. Canaries suit infrastructure changes; flags suit user-visible features. Many teams use both.

How long should each rollout step last?

Long enough for a problem to show up in the exposed group: that depends on traffic and on what could go wrong. A step on a busy service can be minutes; a step for a feature that is used once a week needs days. Decide the pause and the rollback rule before you start.

Why do users stay in their group when the percentage grows?

Rollouts hash a stable id, such as the user id with the flag key, into a bucket. A user whose bucket is below the percentage is in the group, so widening the percentage only adds users and never reshuffles the ones already inside.

Roll out gradually, with a watch on it

Percentage rollouts with consistent bucketing on every plan, and Release Watch to pause a rollout when a metric breaks.

Start for free