TWS can record messages exchanged with an API client. Open API → Settings, enable Create API message log file, and use the requested logging level. Enable logging before reproducing the problem so the useful event is captured.
Educational software guidance. Trading involves risk. Read the financial and information disclaimers.
Step by step
- 1 Open Global Configuration → API → Settings.
- 2 Select Create API message log file and set Logging Level to Detail when collecting a diagnostic case.
- 3 Decide whether market-data logging is needed; it can increase log size a lot.
- 4 Apply the change, reproduce the issue once, and record the time and time zone.
- 5 Export the needed log through TWS and remove secrets before sharing it with support.
A practical example
You turn on logs at noon, but the failure happened at eleven. The new setting cannot recreate the old messages. Leave it on for a planned repeat of the issue, note the exact time, and export that short case. If you add price data to the log, watch file size too. Turn a focused diagnosis into a small file support can read, not a large dump with no clear start point.
Screen reference
Start in Mosaic with File → Global Configuration. Then choose the panel named in the steps.




Mistake to avoid
Common questions
Will enabling logs recover yesterday’s missing messages?
No. Capture must be enabled when the event occurs.
Are local logs always plain text?
IBKR documents encrypted local logs and an export workflow for reading them.