Dear Community,
An essential part of live trading is keeping your algorithms' internal state intact for as long as possible. If you’ve configured indicators or loaded data into memory, restarting the process from scratch can be painful and potentially result in losing valuable state.
Unfortunately, some brokers require weekly re-authentication. If you miss the authentication window, you’re disconnected from the brokerage, and historically, we’ve terminated the algorithms as a precaution.
We returned to the drawing board and devised a smoother way to handle these misses. Now, when you miss the re-authentication request, your algorithm will hang in limbo - alive with its state intact, but disconnected from the brokerage. You will have until the market opens to restore the brokerage connection.
Your algorithm will now send you an email allowing you to restart the authentication process. With Interactive Brokers, this will restart the 2FA process - driving a push notification to your phone as usual. Soon, with Charles Schwab, it will send you an email to restart the OAuth connection.
This lets you start the connection process when you’re already on your phone or computer and paying attention. We scan your portfolio and determine the latest safe time possible, keeping the algorithm online until then. For US Equities strategies, this will be 9.15 a.m. ET on Monday.
This is a universal and safe way to keep your algorithm online as long as possible. It's available from LEAN version v17339 onward, through our Cloud Platform. If you have a current live trading algorithm, you will need to stop and redeploy it to take advantage of this new feature.
Happy Coding!
QuantConnect Team

Robert Wiener
Nice addition! I moved from Schwab to Alpaca because of this. For me IBKR has been manageable because of their mobile authenticator, but still a problem if I am traveling that day, or login to their platform and then need to remember to reauthenticate my live algo.
Matt Pisut
This new method worked great for me this weekend. Thanks !
Jared Broad
The material on this website is provided for informational purposes only and does not constitute an offer to sell, a solicitation to buy, or a recommendation or endorsement for any security or strategy, nor does it constitute an offer to provide investment advisory services by QuantConnect. In addition, the material offers no opinion with respect to the suitability of any security or specific investment. QuantConnect makes no guarantees as to the accuracy or completeness of the views expressed in the website. The views are subject to change, and may have become unreliable for various reasons, including changes in market conditions or economic circumstances. All investments involve risk, including loss of principal. You should consult with an investment professional before making any investment decisions.
To unlock posting to the community forums please complete at least 30% of Boot Camp.
You can continue your Boot Camp training progress from the terminal. We hope to see you in the community soon!