Adding Rules
Create a rule for a feature gate
By default, a feature gate check returns false when there are no rules configured to target a set of users. You can add a rule to a feature gate to expose the new feature to a targeted set of users as follows:
- Log into the Statsig console at https://console.statsig.com
- On the left-hand navigation panel, select Feature Gates
- Select the feature gate where you want to add a targeting rule
- Click the Add New Rule button
You can select the criteria for identifying your target users in several ways:
You can target users based on common application properties such as the operating system that the application is running on as shown below
You can target users based on their attributes; for example, you can select the user's Email attribute and the Contains any of operator, and enter the email domain of your company to target only internal employees as shown below
You can target users in a defined segment as shown below
You can target users who are eligible for another feature gate as shown below; this ensures that this feature gate is activated only for users who pass (or fail) the selected target gate check
Click the Add Rule button
You can optionally edit a percentage share of eligible users who see the new feature (treatment/pass) vs. the default (control/fail) behavior by clicking on the edit icon for the rule
- Click the Save Changes button at the top right corner of the Rules section