Cloud & DevOps

What is Feature Flag?

Quick answer

A switch in software that turns a feature on or off for some or all users without deploying new code.

Feature Flag, explained

Feature flags, also called feature toggles, wrap new functionality in a condition that can be changed from a dashboard or configuration file. This separates deploying code from releasing a feature, so teams can ship unfinished work safely, turn features on for specific users, and switch off a problem feature instantly.

For example, a restaurant ordering platform might enable a new loyalty points screen only for staff and a few pilot restaurants, then roll it out more widely once feedback is positive. Feature flags also support A/B testing and canary releases. The main drawback is clutter: flags left in the code after a feature is fully launched add complexity and potential bugs, so teams should remove old flags on a regular schedule.

Related terms

Guides that mention Feature Flag