> ## Documentation Index
> Fetch the complete documentation index at: https://docs.foff.twospoon.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Features: create and configure flags inside a Foff scope

> A feature is a named flag or config value inside a scope. Learn how to create features, set default values, and understand what value types Foff supports.

A feature is an individual flag or configuration value that lives inside a scope. Every user, team, or organization that your application serves will receive a feature's value when it is queried — unless a more specific override applies. The default value is what Foff returns when no override matches.

## Feature names

Feature names are slugs: lowercase, hyphen-separated identifiers. For example:

* `dark-mode-ui`
* `max-upload-size`
* `checkout-v2-enabled`
* `rate-limit-per-minute`

<Note>
  Feature names are case-sensitive. `dark-mode-ui` and `Dark-Mode-UI` are treated as two different features. Use a consistent naming convention across your scope to avoid confusion.
</Note>

## Supported value types

A feature's default value — and any override value — can be any JSON-serializable type:

| Type    | Example                       |
| ------- | ----------------------------- |
| Boolean | `false`, `true`               |
| String  | `"v2"`, `"red"`               |
| Number  | `100`, `3.14`                 |
| Object  | `{"limit": 50, "unit": "mb"}` |

Choose the type that best fits how your application consumes the value. Boolean flags are the most common, but strings and objects let you ship full configuration payloads through the same system.

## Creating a feature

<Steps>
  <Step title="Open a scope">
    In the Foff dashboard, navigate to **Scopes** and select the scope where you want to add the feature.
  </Step>

  <Step title="Add a feature">
    Click **Add feature** and enter a slug name — for example, `dark-mode-ui`.
  </Step>

  <Step title="Set the default value">
    Enter the default value that applies to all users unless overridden. For `dark-mode-ui`, set the default to `false` to keep dark mode off by default.
  </Step>

  <Step title="Save">
    Click **Create**. The feature is now live and queryable via the API or any Foff SDK.
  </Step>
</Steps>

## Example: `dark-mode-ui`

After creation, your feature looks like this in the dashboard:

| Field         | Value          |
| ------------- | -------------- |
| Name          | `dark-mode-ui` |
| Default value | `false`        |
| Overrides     | None (yet)     |

Any query for `dark-mode-ui` returns `false` until you add an override for a specific hierarchy path.

## Next steps

Once you have a feature with a default value, you can add overrides to return a different value for specific hierarchy paths.

<Card title="Overrides" icon="sliders" href="/concepts/overrides">
  Learn how to override a feature's value for specific hierarchy levels.
</Card>
