Can you automate trading on Charles Schwab?
Yes. Charles Schwab has an official trading API, and a platform that integrates it can place orders in your existing Schwab account, read back positions and balances, and leave your cash and shares where they are. DeployQuant integrates it. You connect through an OAuth login on Schwab's own site, you grant scoped permissions, and the platform never sees your password. The connection can trade and read. Moving money out is outside its permissions, and disconnecting is up to you whenever you like.
Three facts about the Schwab connection decide how a strategy gets there. It supports US stocks and ETFs. It supports seven order types and three time-in-force settings, listed below. It has no paper trading environment, so every order sent through it is a live order. DeployQuant's own paper mode is separate and needs no broker, which is the usual place to run a strategy before it touches a Schwab account. The Schwab broker guide covers the connection in more detail, and this page answers the wider question of what automation on Schwab involves and what the measured results of the strategy templates say about the rules being automated.
A strategy on DeployQuant can start as a plain-English prompt to the AI builder, as visual blocks, or as Python written against the industry-standard algorithm format. The Blocks view and the Code view show one strategy, and a backtest on minute-resolution consolidated US equity data finishes in seconds. Paper trading on the live feed comes next, then a deployment with real money on a connected broker.
Automation executes the rules it is given. It does not improve them. The backtests on this site show what twelve plain rule sets did on 59 ETFs from 2021-01-04 to 2026-10-02, each starting from $10,000 on daily decisions with no margin. The headline runs charge no fees and no slippage. Some of those rules lost most of the account on some funds. The mechanics of connecting, the controls that sit between a strategy and a real order, and the range of outcomes in the tests follow. Every figure is hypothetical, and a live account can lose money.
What connecting a Schwab account involves
The first step is an authorization. You click Connect, Schwab's login opens on Schwab's own site, and you log in there and grant scoped access. DeployQuant receives a token that carries trade and read permissions. It does not receive your password. This is the OAuth method, and it is how the Schwab connection differs from Alpaca and Webull, which connect with API keys.
The arrangement is what the glossary calls bring your own broker. The platform sends orders and reads fills, and the cash and shares never leave your name. Two kinds of trust are involved, one in software that trades and one in a company that holds your money. Only the first goes to the platform. A brokerage API is the programmatic interface that makes it possible. It allows a program to place orders, read positions and stream account data, and each broker has its own, with its own capabilities. A platform that supports several brokers puts one adapter in front of each, so that authentication, the order lifecycle, error handling and reconciliation live behind it.
The permissions matter more than the technology. The Schwab token covers trading and reading, and nothing else. If you disconnect, the platform loses access. The question of whether it is safe to connect a brokerage account to a trading platform has its own answer in is connecting a broker to a platform safe, which lists four tests: what permissions the connection carries, whether you can revoke it, what stands between a malfunctioning strategy and your account, and whether real trading needs an explicit confirmation.
The last of those is handled with a typed confirmation, which a live deployment requires before any real order goes out, so a stray click cannot start trading. Before that point a strategy can be built, backtested and paper traded without a brokerage account at all.
What orders the Schwab connection can send
Seven order types go through the Schwab connection: limit, limit on close, market, market on close, stop, stop limit and trailing stop. It supports three time-in-force settings: day, fill or kill, and good till canceled. Extended-hours orders are supported. The connection covers equities, which means US stocks and ETFs.
A market order trades at the best available price at once. A limit order sets the worst price you will accept. A stop order turns into a market order once the stop price trades, and a stop limit turns into a limit order. The two on-close types are aimed at the closing auction: a market-on-close order and a limit-on-close order are placed to fill at the close. A trailing stop follows the price at a set distance and sells if the price falls back by that distance.
On time in force, a day order expires at the end of the session. A fill-or-kill order must fill completely and at once or it is canceled. A good-till-canceled order keeps working until it fills or you cancel it, which suits a target order that rests for several days.
The three brokers differ. Alpaca takes limit, market, stop, stop limit and trailing stop orders under six time-in-force settings (cls, day, fok, gtc, ioc, opg) and has a paper environment of its own. Webull supports limit, market, stop and stop limit with day and gtc, and no paper environment, because its US trading interface has none that works. Schwab is the only one of the three that lists the two on-close order types. All three support extended hours and good-till-canceled orders. The comparison of which broker is best for automated trading goes through the differences.
What a strategy can do on a given broker depends on this list. A rule that rests a profit target for days needs good-till-canceled, which Schwab has. A rule that exits at the close needs an on-close type, which Schwab also has. A rule that wants to size an order in fractions of a share depends on whether the broker allows it, and the answer on fractional versus whole-share strategies covers that.
Paper trading before a Schwab deployment
Schwab has no paper environment on this connection. Every order sent to it is a real order. DeployQuant has a paper mode of its own. It feeds a strategy live market data with no broker attached, which gives a test close to live conditions before a Schwab account is involved. The paper trading entry defines the term, and the answer on paper trading versus live explains what it does and does not test. A paper run shows how a strategy behaves on a live feed. Exact fills are out of reach, because no order goes to a broker.
The length of a paper run is its own question, and how long to paper trade before going live addresses it. A second tool is dry-run mode. A dry run goes through the whole order flow and its checks, and stops short of the broker. The first day of a Schwab connection can be a rehearsal with no order sent.
The order of steps on DeployQuant is therefore: build the strategy, backtest it, paper trade it, connect Schwab, deploy with a cash allocation, and type the confirmation. A backtest shows what the rules would have done on past data, and it is hypothetical. A verified backtest is one the platform ran itself, with the same data and engine.
Running several strategies in one Schwab account
Automation on one account usually means several strategies at once. DeployQuant gives each deployed strategy a sleeve, which holds that strategy's own cash, positions and profit and loss. A strategy sleeve is the unit of money, and the rest of the account stays as it was.
The sleeve works as a boundary. An order carries the identity of its strategy, and before it goes out the platform tests it against the cash that sleeve holds. One strategy therefore has no way to spend another's cash. When a strategy liquidates, it sells its own shares and leaves the other sleeves' shares in place. If two strategies both own a symbol, the platform keeps each strategy's piece of the position apart, even though Schwab reports one combined holding.
Cash can be added to a single sleeve, and a single strategy can be paused, resumed or stopped, with no effect on its neighbours. Money in the account that no sleeve claims is never traded, and anything you buy by hand is yours. Every sleeve on the account goes through one broker connection, and an order management system routes the orders along it.
On plans, the free tier has 1 live strategy, and Pro at $10 a month allows up to 20 live at a time. Pro adds cash allocation and top-ups per strategy. Sizing is covered under how much to allocate per strategy, the multi-strategy setup under running several strategies in one account, and the definition in what a strategy sleeve is.
The controls between a strategy and a real order
A misbehaving strategy is the main operating risk in automation, so several checks sit in front of the broker. Price bands reject a limit order whose price is far from the market. A price band is a ceiling on that distance. Dollar caps apply per order and per position, and one more cap applies to how many orders a single sync may send. An order that only reduces exposure passes every cap, so a strategy trying to exit is never held back by a limit built to stop it from entering too heavily.
Two other controls are a dry-run mode, which stops before sending, and pause switches. One pauses a strategy, the other every strategy on a connection, and that second one is what the glossary calls a kill switch. The typed confirmation for real money was covered above.
Bookkeeping follows the broker. The platform takes positions and cash from the fill reports the broker issues, so its records match what traded and not what the strategy hoped to trade. A fill is that report, with price and size. Every decision is stored together with the prices and indicator readings behind it, so any trade can be traced back to its cause.
The answer on what happens if the platform goes down deals with the opposite risk, software that is unavailable. These controls limit what a bad strategy can lose. The loss is the same kind a manual trader of the same rules could have, and the controls leave the possibility of loss in place.
What gets automated: the range of outcomes in the tests
A connection to a broker automates execution. The rules decide the result, and the twelve templates tested on this site give a measured range. Each was run on 59 ETFs with the same $10,000 start and window.
Across the 59 funds, the weekly 7% target had the highest median CAGR at 6.61%. Its median maximum drawdown was 26.26%, and it made a median of 106 round trips. The monthly cycle had 5.46% with a drawdown of 36.63% and 69 round trips. The RSI(2) snapback came in at 4.74% with a 17.47% drawdown, and its median trade count was 166 round trips. The RSI mean reversion rule had 2.98%, the EMA 12/26 trend 2.76% and the trend plus trailing stop 2.61%. The SMA 10/50 trend had 2.12%, the golden cross 2.05% and the 200-day regime filter 1.84%. The dip buyer had 1.33%, and the momentum breakout and 3-month momentum rules had a median of 0%.
The trade counts matter for an automated account. A strategy that makes a median of 166 round trips sends a very large number of orders to the broker over 5.74 years, while the golden cross made a median of 3. Each order is a fill at the broker, with its own price. The headline runs charge nothing for fees or slippage. The cost runs on each strategy page add 5 and 10 basis points per trade, which show that high-turnover rules lose more to friction than low-turnover ones. How often a strategy should trade is the subject of how often should a strategy trade.
The comparison with buy-and-hold is blunt. Against buy-and-hold, the RSI(2) snapback and the weekly 7% target came out ahead on 34 of 59 funds each. Counts for the others were 27 for the golden cross, 26 for the 200-day regime filter and 14 for the monthly cycle. For most rules, on most funds, simply holding did at least as well in this window. The answer on why a strategy underperforms buy-and-hold explains the common reasons.
The fund matters as much as the rule. Holding SPY gave 14.56% a year, a worst drawdown of 23.99%, and an ending value of $21,820.48 from $10,000. On QQQ it returned 16.7% with a drawdown of 34.23%. On IWM it returned 7.5% with a drawdown of 31.34%. TLT returned -8.23% and was still in a 42.77% drawdown at the end. On TQQQ, the 3x fund, it returned 25.35% with a drawdown of 80.77%. On UVXY it returned -48.74% and ended with $215.70. Automating a rule on UVXY would execute that rule faithfully on a fund that lost almost everything, and the leveraged ETF answer covers the TQQQ case.
What automation does not change
Automation removes the manual step of placing an order and the delay of doing it by hand. It does not change what the rule would earn, and it does not remove the difference between a backtest and live trading. The answer on why backtest and live results differ lists the causes, and how to tell if a backtest is trustworthy gives ways to judge one. The headline backtests on this site model no fees or slippage, and they use one window of 5.74 years. A different window or a live feed will produce different numbers.
A Schwab deployment also carries the broker's own conditions, which are outside this page. Account type, margin, trading restrictions and tax treatment belong to your account and to Schwab. For tax questions, the general idea is that automated trades are still trades in your account and can create taxable events, and the details depend on your situation. The page on taxes and automated trading covers the idea in plain words, and a tax professional or Schwab can answer for your own account.
DeployQuant is software and not a broker-dealer. It holds no customer funds or securities and gives no investment advice. Your Schwab account keeps the cash and shares under your name, and Schwab is where every order executes. A backtest cannot settle what a future result will be.
For readers who want to compare brokers before deciding, the guides for Schwab, Webull and Alpaca each list the order types, the time-in-force settings and the connection method. The answers on automating Webull, Alpaca and trading without coding cover the neighbouring questions.
Frequently asked questions
Can you automate trading on Charles Schwab?
Yes. Schwab has an official trading API, and DeployQuant integrates it through Schwab's own OAuth login, with scoped trade and read permissions. Your cash and shares remain in your Schwab account, and the connection has no permission to withdraw or transfer funds.
Does Schwab have a paper trading environment for automation?
No. Orders through the Schwab connection are always live-money. For testing, DeployQuant offers its own paper mode: a strategy trades against the live market feed with no broker attached, and can be deployed to Schwab afterwards.
Which order types can an automated strategy send to Schwab?
The connection supports limit, limit on close, market, market on close, stop, stop limit and trailing stop orders. Time in force can be day, fill or kill, or good till canceled, and extended-hours orders are supported. It covers US stocks and ETFs.
Does the platform see my Schwab password?
No. The login happens on Schwab's site through OAuth, and the platform is handed a token that allows trading and reading. Disconnecting ends that access.
Can I run more than one strategy in my Schwab account?
Yes. Each strategy gets a sleeve holding its own cash, positions and profit and loss. The free plan allows 1 live strategy and Pro, at $10 a month, allows up to 20 together. Any cash you leave out of the sleeves is never traded.
What stops a faulty strategy from sending a bad order?
Several checks run before an order reaches Schwab: price bands on limit orders, dollar caps per order and per position, and a dry-run mode that runs the flow without sending. One switch pauses a strategy and another pauses all of them, and live trading starts only after a typed confirmation. A bad rule can still lose money.
Build it from blocks (or type it in English), backtest it on 5.7 years of minute data in seconds, tweak any parameter, then paper trade it on live data. No card, no broker needed to start.
Terms used here
Related questions
Backtests are hypothetical, computed by DeployQuant's engine on minute-resolution consolidated US market data (2021-01-04 to 2026-10-02, $10,000 starting capital, no margin, no fees or slippage in the headline run; buy-and-hold puts 98% of the account in at the first open, as the templates do) and do not guarantee future results. Nothing on this page is investment advice. Live trading involves risk of loss.