Momentum — selection & rebalancing
How the top stocks are selected
At each rebalance, every S&P 500 company is scored by its trailing 12-month return, skipping the most recent month (the classic "12‑1" momentum):
score = (price one month ago ÷ price thirteen months ago) − 1
The engine sorts all ~500 companies by that score and holds the top N (the strongest performers) in equal weight. The most recent month is deliberately left out because last month's biggest winners often reverse short-term — skipping it avoids buying at a local top. Momentum has high turnover and tends to pile into whatever sector is hottest.
When it buys and sells (the rebalance)
Prices are month-end closes (last trading day of the month). Momentum differs from Market Cap in which close it ranks on: it ranks using the prior month-end (the 1-month skip), then trades at the current month-end close.
Worked example — N = 5, monthly rebalance
Consider the March 2021 rebalance:
- Ranking input: each stock's 12-month return measured through Fri, 26 Feb 2021 (the Feb month-end close) — i.e. Feb 2021 close ÷ Feb 2020 close − 1. March is skipped.
- Wed, 31 Mar 2021 — at the closing bell. Buy the 5 stocks with the highest such returns at 20% each, executed at the 31 Mar close. Sell anything that fell out of the top 5.
- Next month — Fri, 30 Apr 2021 close. Re-rank using the 31 Mar month-end data, trade at the 30 Apr close. And so on each month.
So a "March rebalance" decides on February's data and executes at the end of March. That 1-month gap between the signal and the trade is intentional for momentum (it is the skip), unlike Market Cap, which ranks and trades on the same day.
Because momentum needs a full year of history to compute, the backtest effectively begins about a year after your start date.
Rankings tab vs the backtest — same scores, one month apart
The Rankings tab and the Backtest tab use the identical momentum formula, but they line up the calendar differently. This is the part that trips people up, so here it is in full.
1. The Rankings tab shows a month's own ranking (no skip)
Pick a month in the Rankings tab and you see that month's list, scored on that month's end-of-month close versus the close one year earlier. There is no 1-month skip here — it is a snapshot to look at, not a trade. For example, the May 2026 list is scored like this:
2. The backtest ranks on the prior month's list
The momentum backtest deliberately ranks one month behind the trade (the 12‑1 skip). So the rebalance that buys at the end of June uses the May ranking — the exact same list the Rankings tab shows for May:
Put simply: the stocks the momentum backtest is holding right now are the top names in the Rankings tab's previous month. If June is the latest month, the backtest's current holdings = the Rankings tab's May top‑N. (Top-N Market Cap is different: it ranks and trades on the same month, so its backtest matches the Rankings tab's current month.)
3. The current month updates weekly, then freezes
The dataset is rebuilt once a week (each weekend). For the current, unfinished month, the "month-end" close is simply the latest available Friday — so the current month's Rankings list can shift a little every week as new prices arrive. Once that month ends, its close is locked to the actual last trading day and never changes again; from then on its score is always that month-end vs the same month a year earlier.
Example: through June, the live "June 2026" list re-scores on each new Friday close (5 Jun, 12 Jun, 19 Jun, 26 Jun…). The moment July begins, June is fixed at its 30 Jun close and the live list rolls over to "July 2026", now tracking July's latest Friday.
Why month-end close? Every trade is modeled at the month-end closing price — no specific clock time, next-day open, or intraday fills. Monthly closes keep the backtest auditable.
The Rebalance style controls what happens to the weights at each rebalance — a full equal-weight reset, a reset only when the line-up changes, or trading just the additions and removals.