Running your own backtest
Give the backtester tickers and weights and it returns the record against the S&P 500. What to enter, what you get back and the bias you bring with you.
2 min read
Open the backtesterOn this page5 sections
The backtester in the app takes a list of tickers with weights and tells you how that portfolio would have done. It runs on the daily closes we already hold. You can also ask for one in Ask in plain words.
What you enter
| Field | Meaning |
|---|---|
| Tickers and weights | The portfolio, up to 30 tickers. Weights are scaled to add up to 100%. |
| Rebalance | Never, monthly, quarterly or yearly. Never means buy once and let the weights drift. |
| Start and end | The period. Leave them empty for the longest history your plan allows. |
| Comparison | SPY unless you choose another fund. |
| Cost | Basis points per trade, 10 by default. |
What you get back
- The curve of your portfolio next to the comparison.
- Total return, CAGR, volatility, Sharpe and max drawdown for both. See How each number is computed.
- A year-by-year table and how many years you beat the comparison.
- Each holding's own return and its weight at the end.
- The caveats that apply to this particular run.
When the test starts later than you asked
If one of your tickers has no price before a certain date, the test starts there, and the result names the ticker that limited it. We do not invent prices for the missing stretch. Drop the ticker to test a longer period.
The bias you bring
You are choosing these tickers today, knowing how they did. That is the strongest bias a backtest can have, and every run on hand-picked tickers carries a caveat saying so.
- Ask most people today for three stocks to test since 2019 and they name three that went up a lot.
- A list written in 2019 would have looked different, and some of its names would have failed.
- The test is describing your memory of the winners.
Ways to use it honestly
- Test a portfolio you actually hold, to learn its worst fall and how it compares with simply holding the index.
- Compare two weightings of the same tickers. The hindsight is the same in both, so the difference means something.
- Compare rebalancing schedules for the same portfolio.
- Do not use it to prove that a stock you like was a good idea.
Read next
- Survivorship biasOur stock backtests run on the companies we cover today. The ones that failed along the way are missing, which flatters every result. How much, and what we do about it.
- Costs in a backtestEvery trade in our backtests pays a cost, on by default. What is charged, what is not, and why turnover decides how much it matters.
- The practice accountA paper account with $100,000 of pretend money. How orders fill, what is compared with what, and how it differs from real trading.
Something here wrong or unclear? Tell us. Informational only, not investment advice.