Connection Problems OptionsApp to TWS
1. Checking TWS Settings and Live Data
If you're experiencing connection issues between OptionsApp and Trader Workstation, please check the following points:
1. Make sure your API settings are configured correctly (correct port, Read-Only API disabled, etc.). Feel free to use the screenshots attached below to compare your settings.
Key settings at a glance:
- Enable ActiveX and Socket Clients:
Check the box (enable).
Allows OptionsApp to connect to TWS.
- Read-Only API:
Do not check the box (disable).
OptionsApp must be allowed to actively place orders.
- Socket Port: The port must be the same as configured in OptionsApp under Settings.
- Expose entire trading schedule to API:
Check the box (enable).
Transmits complete trade executions correctly to OptionsApp.
- Master API client ID:
Set to 0.
Prevents conflicts with other API connections.
- Allow connections from localhost only:
Check the box (enable).
Increases security by allowing only local connections.
- Download execution reports: Set to All Available. Ensures complete information about executed orders.
2. If you've set up a daily restart: Check that the Auto Logoff Timer is actually set to "Auto restart" instead of "Auto logoff". Also make sure the restart occurs outside regular trading hours. You can compare your settings here:
3. Do you have live data for SPX and SPY? In TWS, the price fields in the option chain should be colored (green/red), yellow fields indicate missing real-time data. OptionsApp won't function without live data.
4. Check that all data servers are connected in TWS. Click the "DATA" button in the top right of TWS, all connections must show green.
5. After making changes to API settings, a complete restart of both TWS and OptionsApp is required. Please close both applications and restart them.
2. Handling Synchronization Warnings
If you receive a "Synchronization Warning" in OptionsApp, it means that not all required data was loaded correctly when retrieving market data or contract information from TWS. This can be due to missing live data, incorrect time settings, or an unreliable connection to TWS. Often a restart of TWS and OptionsApp helps. If the problem persists, also check your server connection, you may be connected to a non-European IB server. You can find instructions for checking your server in the article TWS Issues and Server Check
3. Optimizing Connection Times
Connection drops occur more frequently at night or on weekends. You can configure in OptionsApp on which days and at what times the connection to TWS should be active. This will reduce the load on TWS and noticeably improve stability. Make sure that the same timezone (e.g., US/Eastern) is set in both TWS and OptionsApp. You can find the corresponding instructions here
It's also recommended to configure an automatic restart (Auto-Restart) in TWS, for example daily at 05:30 PM US/Eastern. To do this, enable the "Auto-Restart" option under "Lock and shutdown" in TWS. You can find detailed instructions for TWS restart settings here: Recommended TWS Restart Settings
If these steps don't help, please go through the points in this article: TWS is frozen ("No response") or heavily overloaded