Overview
Feature flags separate deploy from release. Deploy puts code on the server (applad deploy). Release makes functionality live to users (feature flags). These are independent decisions made by different people at different times.
How Flags Work
Flag skeletons — that a flag exists, its variants, its per-environment defaults — live inflags/*.yaml and are version controlled. Targeting rules (which users see which variant) live in the admin database and are managed through the UI without a deployment.
Flag Types
Boolean Flags
Simple on/off switches:flags/new-dashboard.yaml
Multivariate Flags
A/B tests with multiple variants:flags/checkout-flow.yaml
Creating Flags
Environment Defaults
Set per-environment defaults in the YAML file:flags/experimental-feature.yaml
Using Flags in Code
Applad provides SDKs for all major platforms:Dart/Flutter
JavaScript/TypeScript
Managing Flags
List all flags
Validate flag definitions
View flag details
Enable/disable flags
View evaluation logs
Gradual Rollouts
Instead of flipping a flag on/off instantly, roll it out gradually:- Deploy code with flag off in production
- In admin UI, set flag to 5% of users
- Monitor metrics
- Increase to 25%, then 50%, then 100%
- Flag is now fully released
User Segmentation
Target flags to specific user groups:- Beta users — Users who opted into beta features
- Internal team — Your company email domain
- Specific orgs — Enterprise customers, specific tenants
- User properties — Country, plan level, signup date
Dark Launches
Deploy code to production with flags off, then enable for internal testing:- Deploy with
production: falsein flag YAML - Code is on production servers but inactive
- In admin UI, enable flag only for internal team
- Test feature in production environment with real data
- When confident, enable for all users
Instant Rollbacks
If a released feature causes problems:Flag Lifecycle
- Created — Flag skeleton committed to version control
- Deployed — Flag exists, default is off
- Testing — Enabled for internal team only
- Canary — Enabled for 5-10% of users
- Rollout — Gradually increased to 100%
- Released — Fully enabled for all users
- Cleanup — Remove flag from code and config after feature is stable
Best Practices
One flag per feature
One flag per feature
Don’t reuse flags for multiple features. Each feature gets its own flag with a clear, descriptive name.
Clean up old flags
Clean up old flags
Once a feature is fully released and stable, remove the flag from code and delete the YAML file. Flags are temporary release controls, not permanent configuration.
Use descriptive keys
Use descriptive keys
Flag keys should describe what the flag controls:
new-checkout-flow✓experiment-42✗
Document flag purpose
Document flag purpose
Always include a
description field explaining what the flag controls and why it exists.Default to off in production
Default to off in production
Production environment should default to
false for boolean flags and "control" for multivariate flags. Release is an active decision.Example: A/B Test Configuration
flags/pricing-page-redesign.yaml
- Control: 70% of users
- Variant A: 10% of users
- Variant B: 10% of users
- Variant C: 10% of users
Example: Dark Launch
flags/new-analytics-engine.yaml
- Internal team members
- Beta users who opted in
Next Steps
Messaging
Configure email, SMS, and push notifications
AI Assistant
Use “The Lad” to help manage infrastructure