Once you have a written system, automating it is a natural next step. It is worth being clear about what automation actually fixes — because it is a smaller list than most people expect, and the things it does not fix are the ones that lose money.
What automation genuinely solves
- Consistency. The rule executes identically every time, including on the day you feel certain it will fail.
- No missed signals. A system scanning 200 stocks does not get tired at stock 140.
- Speed of execution. Orders go out the moment conditions are met.
- Honest record-keeping. Every signal and fill is logged automatically, which makes review possible.
- A strategy with no edge. Automating negative expectancy just loses money faster.
- Overfitting. A curve-fitted system runs beautifully and still fails live.
- Your behaviour. Most people override or switch off their own algorithm during a drawdown.
- Costs. Automation often increases turnover, and turnover is friction.
The regulatory position in India
Automated order placement through a broker’s API sits within a regulated framework. SEBI has progressively tightened requirements around algorithmic access for retail — including broker responsibility for the strategies routed through them, and approval requirements for certain categories of automated order flow.
The gap between backtest and live
| What the backtest assumed | What actually happens |
|---|---|
| Fills at the closing price | You fill at the next open, or somewhere across the spread |
| Zero slippage | Slippage grows with size and shrinks with liquidity |
| Every signal taken | The API times out, the internet drops, the broker rate-limits you |
| Costs ignored or estimated | STT, stamp duty, GST and DP charges on every round trip |
| Instant execution | Latency, queue position, partial fills |
A sane build order
- 1Trade the rules by hand first
For several months. You will discover ambiguities in your own rules that only surface when you have to apply them to a real chart at 3:20pm.
- 2Automate the scan, not the order
Have the machine find candidates and tell you. You still place the trade. This captures most of the consistency benefit with none of the execution risk.
- 3Paper-trade the full automation
Run it end to end against live data without real money, and compare its signals to your backtest. Divergence here is information about your assumptions.
- 4Go live small, with a kill switch
A hard maximum daily loss that shuts everything down, and a way to stop it manually in seconds. Every experienced systematic trader has needed this.
- 5Log everything and reconcile daily
Compare intended orders to actual fills. Unexplained differences are bugs, and bugs in trading code cost money continuously until found.
Washing machine achha dhota hai kyunki usme program fix hai. Par kapda galat daala toh machine bhi kuch nahi kar sakti. Algo bhi wahi — woh aapki strategy tez chalata hai, sudhaarata nahi. Kharab rules ko automate karoge toh nuksaan bhi automatic ho jaayega.
- Automation improves consistency and execution. It does not create an edge.
- Check your broker’s API terms and current SEBI rules before building.
- The backtest-to-live gap runs in one direction and widens with frequency.
- Automate the scan before automating the order.
- A kill switch and daily reconciliation are not optional.
Mark it done to track your progress through the curriculum.
Common questions
Short, direct answers to what people ask about this topic.
- does automating a strategy give you an edge
- No — automation is an execution improvement, not an edge. It buys consistency, no missed signals, faster order placement and honest logging, all of which are genuine. But if the rules do not make money when followed by hand, they will not make money when followed by a script; they will simply reach the same conclusion sooner, with more trades and more costs along the way.
- is algo trading allowed for retail investors in India
- Automated order placement through a broker’s API sits inside a regulated framework rather than being freely open. SEBI has progressively tightened the requirements around retail algorithmic access, including making brokers responsible for the strategies routed through them and requiring approval for certain categories of automated order flow. The detail changes, so check your broker’s current API terms and the prevailing SEBI rules before building anything.
- the difference between the price a backtest assumed and the price you actually get is called
- Slippage. It grows with position size and shrinks with liquidity, and it is only one of several frictions a naive backtest ignores — the others being latency, queue position, partial fills, and the real transaction costs a live account pays — STT, stamp duty, exchange charges, GST, and DP charges on delivery sells.
- why do intraday systems fail live when the backtest looked good
- Because the gap between backtest and live results runs almost always in the same direction and it widens with trading frequency. A daily-timeframe system pays slippage, spread and charges a handful of times a month and loses relatively little to them. A system trading many times a day pays them on every round trip, which is enough to consume the entire theoretical edge of a strategy that tested well.
- what is a kill switch in algo trading
- A kill switch is a hard limit that shuts the whole system down by itself — most commonly a maximum daily loss — together with a way to stop it manually within seconds. It exists because trading code fails in ways that cost money continuously until somebody notices, and because APIs time out, connections drop and brokers rate-limit at inconvenient moments.