For AI agents: a documentation index is available at the root level at /llms.txt and /llms-full.txt. Append /llms.txt to any URL for a page-level index, or .md for the markdown version of any page.
Sign inTry it free
DocsGuidesSDKsIntegrationsAPI docsTutorialsFlagship blog
DocsGuidesSDKsIntegrationsAPI docsTutorialsFlagship blog
  • Get started
    • Overview
    • Onboarding
    • Get started
    • Launch Insights
    • LaunchDarkly architecture
    • LaunchDarkly vocabulary
  • AgentControl
    • AgentControl
    • Manage AgentControl
  • Feature flags
    • Create flags
    • Target with flags
    • Flag templates
      • Custom flags
      • Release flags
      • Kill switch flags
      • Experiment flags
      • AI prompt flags
      • AI model flags
      • Migration flags
    • Manage flags
    • Code references
    • Contexts
    • Segments
  • Releases
    • Releasing features with LaunchDarkly
    • Release policies
    • Percentage rollouts
    • Progressive rollouts
    • Guarded rollouts
    • Feature monitoring
    • Release pipelines
    • Engineering insights
    • Release management tools
    • Applications and app versions
    • Change history
    • Restoring previous flag versions
  • Observability
    • Observability
    • Session replay
    • Error monitoring
    • Logs
    • Traces
    • Observability metrics
    • Product analytics events
    • LLM observability
    • Alerts
    • Dashboards
    • Service map
    • Vega for auto-remediation
    • Observability MCP server
    • Search specification
    • Observability settings
    • Observability integrations
  • Experimentation
    • Experimentation
    • Experiment metric types
    • Experiment configuration
    • Managing experiments
    • Analyzing experiments
    • Multi-armed bandits
    • Holdouts
  • Metrics and events
    • Metrics in LaunchDarkly
    • Creating metrics
    • Metric groups
    • Events
    • Autogenerated metrics
  • Warehouse native
    • Warehouse native metrics
    • Setting up external warehouses
    • Creating experiments using warehouse native metrics
  • Infrastructure
    • Connect apps and services to LaunchDarkly
    • LaunchDarkly in China and Pakistan
    • LaunchDarkly in the European Union (EU)
    • LaunchDarkly in federal environments
    • Public IP list
  • Your account
    • Projects
    • Views
    • Environments
    • Tags
    • Teams
    • Members
    • Roles
    • Account security
    • Feature previews
    • Billing and usage
    • Changelog
Sign inTry it free
LogoLogo
On this page
  • Overview
  • About kill switch flags
  • Create kill switch flags
  • Modify the kill switch flag template
Feature flagsFlag templates

Kill switch flags

Was this page helpful?
Previous

Experiment flags

Next
Built with

Overview

This topic explains how you can use kill switch or circuit breaker flags to shut off functionality. These flags are permanent safety mechanisms that you can use to turn off non-core functionality or third-party tools in an emergency.

About kill switch flags

Kill switch flags, sometimes called circuit breaker flags, are permanent boolean flags with two variations: “Enabled” (true) and “Disabled” (false).

Kill switch flags are operational flags that control or change how your app or service operates. Often, these changes happen in response to unplanned events, such as traffic spikes or third-party service failures. You can use these flags to quickly turn off functionality when needed. You can also integrate these flags with observability or application performance management (APM) tools to automate flag shut off. To learn more, read Monitoring tools.

Create kill switch flags

To create a kill switch flag:

  1. Click Create and choose Flag. The “Create flag” dialog appears.
  2. Enter a unique, human-readable Name. A suggested key auto-populates from the name you enter, but you can customize it if you wish.
  3. (Optional) Click Edit key to update the flag key. You’ll use this key to reference the flag in your code.
  4. (Optional) Enter a Description of the flag. A brief, human-readable description helps your account members understand what the flag is for.
  5. (Optional) Click No template and select Kill switch.
  6. (Optional) Change the default on and default off variations if needed.
  7. (Optional) Click on your member name to change the flag maintainer.
  8. (Optional) Click the tag icon to add one or more tags.
  9. (Optional) Click the views icon to add the flag to a view.
  10. (Optional) Click All SDKs to make the flag unavailable to client-side or mobile SDKs. Flags are available to all SDKs by default.
  11. (Optional) Click Temporary to change the flag from temporary to permanent.
  12. Click Create flag.

The flag Targeting tab appears.

After you create a flag, you can make further changes to it as needed, such as to update flag targeting.

To learn more, read Creating new flags.

Because kill switch or circuit breaker flags are used to shut off functionality or third-party tools completely, they typically do not use complex targeting rules. Instead, they serve “Enabled” by default when targeting is on, and “Disabled” when targeting is off. To learn more about targeting, read Target with flags.

Modify the kill switch flag template

To modify your kill switch flag template:

  1. Click the project dropdown. The project menu appears:

The project menu.

The project menu.
  1. Select Project settings.
  2. Select Flags. The Flags settings list appears.
  3. In the “Flag templates section, click the pencil icon next to “Kill switch.”
  4. Choose Yes or No to mark all kill switch flags as temporary or permanent. Kill switch flags are usually permanent.
  5. In the “Variations” section, edit the flag variation Names.
  6. In the “Default variations” section, choose which default variations to serve when the flag is toggled On or Off.
  7. In the “Tags” section, type to add tags to each new flag by default.
  8. Click Save.

Verify that the updated default template settings are correct by navigating to the Flags list and creating a new kill switch flag.