Skip to main content

Setting up an SDK


This guide provides a high-level overview for setting up an AppFlags SDK in your application. For a more detailed guide on a particular SDK, refer to the SDK documentation.

Setting Up and Configuring an SDK

The process for setting up and configuring an SDK in your application is generally the same across the various SDKs.

To set up the SDK:

  1. Install the AppFlags SDK with the dependency manager for your project.

  2. Import the AppFlags client into your code and initialize it. Initialization requires an SDK key for the particular Environment (e.g. production or staging).


    Depending on the SDK you are using, you will either need to use a client-side SDK key or a server-side SDK key. For more info, see SDK Keys.

  3. Use the AppFlags client to access your Feature Flags.

Client Initialization

When the AppFlags client is initializing, it makes a request to the AppFlags edge servers to download your Feature Flags. This process typically takes around 100ms.

Once the AppFlags client is initialized, Feature Flags will be returned immediately with no delay.

Until the AppFlags client is initialized, it will not be able to return Feature Flags. For a client-side SDK, you may choose to show a default behavior or delay rendering a component until Feature Flags can be resolved. For a server-side SDK, you may choose to delay server startup until the AppFlags client is initialized. Since initialization only takes around 100ms, this will not cause a noticeable delay to your users.