Linda
By Linda
August 16, 20234 min read

Flexibility and control with feature flags for custom software

Feature FlagsSoftware Development

Most Glossary · In briefSaaSSaaS stands for Software as a Service: software a provider manages centrally and makes available to users over the internet.Read more⁠ products offer their services in different subscription forms. Think of packages ranging from 'basic' to 'premium gold ++', each with its own price and matching features. Giving different users access to specific functions, purely based on their subscription, is not always easy. Luckily there is a very suitable solution for that: Glossary · In brieffeature flagA feature flag is a setting that enables or disables software functionality without another code deployment. It can apply to all users or a particular group.Read more⁠! In this blog we dive into the basics of feature flags, what they actually are and why you would want to integrate them into your custom software.

What are feature flags?

Feature flags, also called feature toggles, let developers switch certain functions or bits of code on and off, without code changes or extensive Glossary · In briefreleaseA release is an identifiable software version prepared to be made available to users. It brings together one or more checked changes.Read more⁠. That way you can give different user groups, based for example on their subscription, role or for experiments, very targeted access to specific functionality. Feature flags are widely used in Glossary · In briefA/B testAn A/B test is an experiment in which two groups each see a different variant. Comparing their behaviour shows which variant performs better against a predefined goal.Read more⁠ (read here more about the why) of new software parts, where a small group of users gets a new feature. That can then be tested thoroughly and you limit the risks with it.

Why would you want to use feature flags?

Adding feature flags to your custom software brings several advantages. You can gradually roll out new functions by making them available at first only to a limited group of users. That way you keep the risks small and gather feedback before a feature reaches a larger audience.

Besides that you can use feature flags to switch functions off quickly if problems arise. Instead of having to Glossary · In briefrollbackA rollback reverses a change so software, configuration or data returns to an earlier state. Teams use it when a change causes errors or other unwanted effects.Read more⁠ an entire release, you simply switch off the problematic feature to stop users from still being able to reach it. Meanwhile you fix the issue.

By switching off a single feature you solve the problem, without the headache of a complete release rollback.

You can also use feature flags to personalise the Glossary · In briefuser experienceUser experience, often abbreviated to UX, is the overall experience someone has when using a product, system or service.Read more⁠. By switching functionalities on and off based on set criteria you adapt your software to the wishes and preferences of individual users, or complete user groups.

Finally feature flags make it possible to offer the user exactly what they need, and at a sharp rate. Customers often use only a portion of your software. Exactly that part you can then offer more affordably to the end user, and also sell specific (newer) features as a separate add-on.

How do you add feature flags?

How you set up feature flags depends rather on the stack you already work with and what you find comfortable. Sometimes you put a few conditional statements directly in the code, simple enough, while with a larger team or product you often end up with external tooling that takes the switching work off your hands. Just choose something that stays flexible and that does not load your team with long-term maintenance and management, because then the fun is gone quickly. We can help you with that by the way ;).

When yes and when not

The real power sits in situations where you want to determine exactly who sees a new function when. If you develop continuously, and have many product lines or features in the pipeline, this approach is gold for scaling calmly. Before you roll it out broadly you gather feedback in doses, and it also feels a lot safer for end users if changes creep in gradually.

But watch out, because it also lays an extra layer of complexity over your product, especially if you have many user groups and parallel flags running through each other. And on exactly those weak points you break your neck later when you do not maintain an iron-strong structure and a clear clean-up policy.

Key takeaways

  • You are no longer stuck with one static build. Feature flags make software looser and that is exactly what custom work needs to keep pace with how your organisation develops.

  • Think of switching on a function for a test group and gradually scaling up while you gather feedback. That way you give user groups personalised functionality and roll out new features gradually.

  • It does not indeed get simpler. Every flag you hang in the system produces a fork in the logic and that yields more paths to test, more technical debt you will have to prune through once the trial is done.

  • And yet the advantages often easily outweigh that once your environment runs on switching fast and short feedback rounds.

Ewout

Contact person: Ewout

Work together?

Have a software question or a project in mind? Get in touch with Ewout to discuss what you need and how we can help.

CONTACT

Get in touch with us

Have a question or want to discuss your software? Leave your details and we will get back to you soon.