# What Is a Kill Switch in Software Development?

Learn everything you need to know about kill switches and learn how to use a kill switch as part of your strategy to save time and money on product recalls.

Source: https://amplitude.com/en-us/explore/experiment/what-is-a-kill-switch-in-software-development

---

###### Kill switches explained

# What Is A Kill Switch In Software Development?

Learn everything you need to know about kill switches and learn how to use a kill switch as part of your strategy to save time and money on product recalls.

<!--$-->

Table of Contents

-

In software development, a kill switch is a mechanism for disabling a program or turning off a specific feature when needed.

It’s typically used in an emergency, such as data theft prevention. For example, VPN services might use a kill switch to turn off a user’s internet connection should the server fail, protecting the IP address from hackers.

Every kill switch is different. Depending on how it has been designed, kill switches vary in their capacity for limiting or shutting down a program.

Find out how kill switches work and how development and operational teams can use them to their benefit.

Browse this guide

- [How does a kill switch work?](#how-it-works)

- [Examples of kill switches in software development](#examples)

  - [Mobile apps](#mobile-apps)
  - [Feature flags](#feature-flags)

- [Benefits of kill switches](#benefits)

  - [Feature release management](#feature-release-management)
  - [Network system loads](#network-system-loads)
  - [Incident management](#incident-management)

- [Kill switches and testing software](#testing)
  - [Impact on development and operations](#impact-on-development-and-operations)

- [Using kill switches in Amplitude](<#using-amplitude-benefits >)

<!--/$-->

## How does a kill switch work?

The term “kill switch” has various meanings depending on the type of technology you’re discussing. Its original usage referred to a physical button that would be hit to shut off machinery in dangerous situations.

In software, a kill switch is built into the code. It can be activated by various triggers, such as unauthorized activity, detection of external tampering, or a command sent by the central server.

If the server sends a "kill" command or the software fails to check in, this could indicate potential issues like disconnection or tampering. In this scenario, the kill switch would be activated.

The kill switch follows several authentication steps where unauthorized activity is detected to ensure the trigger is correct. It will then activate according to your plan.

The kill switch can perform various actions depending on different development commands and the severity of the trigger. These can include:

- Disabling specific features or the entire software
- Limiting functionality
- Deleting or encrypting data

If the issue is resolved, you can program the kill switch to allow reactivation. This might involve re-authenticating with the server, updating the software, or correcting any violations that triggered the kill switch.

## Examples of kill switches in software development

Several environments might require a kill switch, so there are various kill switch types to fit each unique situation.

### Mobile apps

App store operators, such as Apple App Store or Google Play Store, can remotely disable or remove apps from a user’s device. This type of kill switch may be used to protect the security of apps the platforms manage.

Regularly monitoring apps for compliance and potential security threats sends detection signals to the app store. Platform operators then decide on the appropriate next steps, which can be done remotely.

### Feature flags

Sometimes called toggles, [feature flags](https://amplitude.com/explore/experiment/feature-flags-best-practices) enable developers to disable specific features within an application. If a feature is found to have a bug or security flaw, it can be quickly turned off without deploying new code. These flags can be permanent or short-term.

## Benefits of kill switches

While developers hope there will never be a need to use a kill switch, having one at the ready can be beneficial, helping safeguard your product and users.

### Feature release management

When using a feature flag as a kill switch, you can disable specific underperforming features without recalling the entire product.

Isolated recall means users can keep using most of your product’s offerings, reducing overall disruption and avoiding total negative impact. Focusing on recalling only the impacted features can also save developers time on fixes.

### Network system loads

A kill switch can be used for application load management, disabling specific features to reduce system load stress.

The software server might become overloaded during times when traffic is very high. For [ecommerce](https://amplitude.com/industry/ecommerce) brands, traffic could be particularly difficult to manage during peak buying times like Black Friday. Shutting off a feature that falls outside the Black Friday trend could ease space on the server for improved network loads. Doing so can prevent potential damage to the functionality of your platform.

### Incident management

The option of immediate mitigation is crucial in cases where data is at risk of being breached.

Kill switches allow you to immediately deactivate specific features or the entire product when triggered by a data security breach. This protects your users, the organization, and brand authority and trust.

## Kill switches and testing software

A kill switch can prove especially valuable during software testing.

Let’s say you’re conducting a beta test with a select set of users to trial the software before it’s ready for final [launch](https://amplitude.com/blog/product-launch).

You might discover a major bug not detected in earlier tests that would have a detrimental impact on product engagement and feedback if seen by the beta testers. In this scenario, a kill switch can prevent users from seeing the specific software element or feature that has a bug.

Cutting off access gives developers time to fix the problem before releasing the feature back to the users.

Developers conducting [A/B testing](https://amplitude.com/blog/ab-testing) may use a feature flag as a kill switch. While trialing two different versions of a product release, a feature flag kill switch makes it possible to switch between the two to isolate specific features.

### Impact on development and operations

Having a kill switch ready is useful for both development and operational teams. However, implementing one requires effective [management](https://amplitude.com/blog/role-of-feature-management) and maintenance strategies.

Build a centralized system where all kill switches can be accessed easily and consistently. Document the purpose and configuration of all key switches. This enables quick decision-making when activation is needed. You should also regularly monitor kill switch activations and assess their overall impact.

All teams involved in using and monitoring kill switches should be trained on their importance and shown how to use them when needed. It’s important to [build a culture of knowledge](https://amplitude.com/blog/create-data-privacy-security-culture) around their usage and practice regular drills to ensure everyone knows how to act if the time comes.

## Using kill switches in Amplitude

[Amplitude Experiment](https://amplitude.com/amplitude-experiment) offers everything development and operational teams need to ensure safe releases and robust products.

Engineering teams can use Amplitude’s feature flags to implement kill switches. With our intuitive software, you can instantly update or turn off feature flags and make quick modifications while avoiding significant impact.

[Sign up to Amplitude today](https://app.amplitude.com/signup) to use our feature flags when you need it most.

## Explore related content

[ExploreWhat Is Statistical Significance? How To Calculate It](/explore/experiment/statistical-significance-guide)[ExplorePainted Door Tests: Everything You Need to Know](/explore/experiment/painted-door-testing)[ExploreEverything To Know About Stratified Sampling](/explore/experiment/stratified-sampling)[ExploreWhat Is Progressive Delivery? A Quick Overview](/explore/experiment/what-is-progressive-delivery)[ExploreWhat Is Product Experimentation?](/explore/experiment/product-experimentation)[ExploreWhat Is Release Management? A Complete Guide](/explore/experiment/what-is-release-management)[ExploreWhat Is Visual Testing? Best Practices & Benefits ](/explore/experiment/what-is-visual-testing)[ExploreWhat Is A Beta Test? Beta Testing Explained](/explore/experiment/what-is-beta-testing)
