
How to configure TWS for continuous trading with a single weekly login?
Interactive Brokers’ Trader Workstation (TWS) is famous for its robustness — but also for its daily logoff. By default, TWS disconnects once every 24 hours, forcing many users to believe they must manually re-enter their username and password every morning. With TWS Auto Restart, this hassle disappears.
That may sound like a necessary evil… but it’s not. With just a couple of settings, you can keep TWS + Email Trader running securely for an entire week, with almost no interruption (only the 2–3 minutes of the scheduled daily restart).
The Daily Logoff: The Default Behavior
By default, TWS enforces a daily shutdown (See official IBKR Documentation). The idea is to refresh contract definitions and keep the platform clean.
But for automated setups like Email Trader, this behavior looks like a roadblock:
-
You log in once → everything works.
-
Next morning → TWS forces you to log in again.
-
Result: automation feels broken.
The Truth: Weekly Authentication Tokens
What IBKR doesn’t always make obvious is that your login creates a weekly authentication token.
-
Valid for ~7 days (until Sunday ~01:00 ET).
-
As long as the token is valid, TWS can close and restart automatically without asking credentials again.
-
You only need one manual login per week.
So the “daily manual login” isn’t a technical limitation — it’s just the default configuration.
The Fix: Auto Restart Configuration
Here’s how to unlock a full week of smooth, automated trading with Email Trader + TWS:
-
Open the Settings menu in TWS (top-right of the main screen).

-
Go to Lock and Exit. (see IBKR Lock and Exit page for more information)
-
Set an Auto Restart Time during market downtime (e.g. 01:45 AM).
-
Select Auto restart instead of Auto logoff.

-
Click Apply, then OK.
-
Repeat the same configuration for both Paper Trading and Live Trading, since their settings are independent.
What Happens Next
-
TWS now shuts down and restarts automatically every night at the chosen time.
-
The API is unavailable for only ~2–3 minutes.
-
As long as your weekly token is valid, TWS reconnects without asking for username/password.
-
Email Trader hooks back into the API automatically after the restart.
You’ll only need to log in manually once per week (usually on Sunday night).
Security Considerations
-
No password is stored in plain text — IBKR handles secure tokenization.
-
Auto restart uses the same security model as a manual login.
-
This solution is fully supported and does not compromise your account.
Conclusion
Think of it this way:
-
7eleven: open daily, but you still need to show up and check in.
-
24/7: configure once, and enjoy continuous service all week long.
With this setup, TWS + Email Trader becomes a reliable, near-24/7 trading solution, with only a tiny interruption each night.
No more morning re-logins, no more broken automations — just peace of mind.