Generate Flex Token

The Flex Token is a unique access pass for authenticating requests to the Interactive Brokers Flex Web Service. Follow these simple steps to retrieve it:

1. Log in to the Client Portal:
Start by logging into your Interactive Brokers Client Portal.

2. Navigate to Flex Queries:
Go to the main menu and select "Performance & Reports" > "Flex Queries".

Interactive Brokers main menu with "Performance & Reports" selected and the "Flex Queries" option highlighted.
Interactive Brokers main menu with "Performance & Reports" selected and the "Flex Queries" option highlighted.

3. Access the Configuration Screen:
Look for the Flex Web Service Configuration section and click the gear icon next to it.

"Flex Web Service Configuration" section in IBKR, showing the gear-shaped setting icon used to open the configuration window.
"Flex Web Service Configuration" section in IBKR, showing the gear-shaped setting icon used to open the configuration window.

4. Enable the Service:
In the configuration window, check the box to enable the Flex Web Service Status.
Click "Save".

The Flex Web Service Configuration window with the "Flex Web Service Status" checkbox selected and the "Save" button.
The Flex Web Service Configuration window with the "Flex Web Service Status" checkbox selected and the "Save" button.

5. Set Activation Duration and generate the token:
Choose the "Expire After" period. Click "Generate New Token" to continue.

Configuration screen showing the "Expire After" dropdown menu and "Generate New Token" button.
Configuration screen showing the "Expire After" dropdown menu and "Generate New Token" button.

6. Save and Copy:
Your new Current Token will be displayed.
Click "Save".
Copy this token immediately, as you will need it for the setup process.

"Current Token" field in the IBKR portal, displaying an active token for copying.
"Current Token" field in the IBKR portal, displaying an active token for copying.