Guide
How this works
A plain-English guide to testing your trading ideas. No coding, and no jargon you can't look up in two minutes.
What is this?
Say you have a trading idea, like "buy when the price crosses above its 20-day average." Instead of trading it live and hoping it works, you can test it on years of past data first, in seconds.
You tell the tool two things: when to buy a stock, and when to sell it. It then goes back through history, day by day, pretending to trade your rules on real stock prices, and shows you what would have happened.
Set up your test
Before building any rules, fill in a few basics on the left side of the builder. Think of it as setting the stage for your test.
Dates & market
Brokerage & slippage
Buy & sell rules
Every rule is just a sentence comparing two things. It always reads left to right: this value, then a comparison, then that value.
In plain words: "Buy when today's closing price is higher than its 20-day moving average." That's the whole rule.
Looking at past days
Next to most values there's a small number box. That's how many days back to look. Leave it at 0 for "today." Change it to check yesterday, or the day before.
Close, box = 0→ today's closing price.High, box = 1→ yesterday's highest price.
Combining rules
Sometimes one comparison isn't specific enough, and you want to do a bit of math first. Click + Term to add another value, and connect them with +, -, ×, ÷.
Example: a gap-up morning
Today's Open > Yesterday's Close × 1.02Buys when the stock opens at least 2% above where it closed yesterday, a classic "gap up."Grouping things together
Abs(Open − Close) <= Bracket(High − Low) × 0.1This spots a "Doji" candle, a day where the price barely moved from open to close relative to its full range. You don't need to memorise this one. It's here to show how grouping works.Picking winners
Some days, 15 different stocks might all match your buy rules at once. But you don't have unlimited money, so which ones do you actually buy?
That's what Tie Breaker is for. It ranks all the matching stocks by something you choose, and picks the top ones.
A common choice: highest volume
Reading your results
Equity curve
Max drawdown
Example strategies
Four examples below, each showing a different trick you can use in the builder. The rows look the way they will on the Custom Backtest page.
Breakout
Using percent change, and requiring two things to both be true at once.
This looks for a stock that is moving fast and being traded a lot at the same time. If the price jumps but nobody is buying it, that could just be noise. But if the price jumps and a lot of people are trading it, that's a stronger sign something real is happening. There's no sell rule. You just get out using stop loss or target.
Exit: Stop Loss 5% · Take Profit 10%
Doji reversal
Using Abs to ignore whether a number is positive or negative.
Abs just means "turn the number positive." Here, it doesn't matter if the price ended slightly higher or slightly lower than it opened. We only care that it barely moved. That's a sign buyers and sellers were stuck in a standoff, which often happens right before the price flips direction.
Trend rider
Stacking two buy rules that must both pass.
Every buy row you add has to be true at the same time. Here, the price must be above the trend line, and the momentum must also be pointing up. Asking for both to be true at once means fewer bad trades than checking just one.
RSI bounce
Stacking two sell rules, where either one can trigger the exit.
Sell rows work differently. You get out as soon as any one of them comes true, not all of them. So here, you sell either when RSI shows the bounce is over, or earlier if the price drops back below its 20-day average, whichever happens first.