# Enable Flex UI 2.x.x on your account

This page explains how to enable Flex UI 2.x.x on your Flex application. For more information about the entire migration process, see [Migrate from Flex UI 1.x.x to 2.x.x](/docs/flex/developer/ui/migration-guide).

## Enable Flex UI 2.x.x on your account

### Using the Flex UI versions page

You can install Flex UI 2.x.x on the [**Flex UI versions**](https://console.twilio.com/us1/develop/flex/settings/ui-versions) page in Twilio Console.

If you're running a 1.x.x version, select 2.x.x and click **Confirm**. If you're on a public beta version of 2.x.x, install 2.x.x by clicking on the 2.x.x version link and then **Install**.

### Using the Configuration service API

To change the `ui_version` and reset your `ui_dependencies`, you can make the following curl request. Change the version number in this curl request (`2.x.x`) to the current version number that you're migrating to. You can retrieve your account SID and auth token from [the Twilio Console](https://twilio.com/console).

```javascript
curl --request POST \
 --url https://flex-api.twilio.com/v1/Configuration \
 -u ACXXXXXXXXXXXXXXXXXXXXX:auth_token \
 --header 'accountsid: ACXXXXXXXXXXXXXXXXXXXXX' \
 --header 'content-type: application/json' \
 --header 'i-twilio-auth-account: ACXXXXXXXXXXXXXXXXXXXXX' \
 --data '{
   "account_sid": "ACXXXXXXXXXXXXXXXXXXXXX",
   "ui_version": "~2.x.x",
   "ui_dependencies": {}
}'
```

### Self-hosted Flex

You can install Flex UI 2.x.x via yarn or npm:

## yarn

```bash
yarn add @twilio/flex-ui@^2
```

## npm

```bash
npm install @twilio/flex-ui@^2

```

Refer to [Upgraded dependencies](/docs/flex/developer/ui/migration-guide/migration-guide-update-dependencies) if you run into compatibility issues which you will need to resolve.

### Using the flex-ui-sample package

To use the **flex-ui-sample** package for bootstrapping your project, make sure to pull the latest from the **main** branch of the [flex-ui sample repo](https://github.com/twilio/flex-ui-sample/) which requires the **@twilio/flex-ui@^2** package. We've also bumped React to version 17 to satisfy the Flex 2.x.x requirements. This means that on any existing project, you have to resolve compatibility issues in your code should they occur.
