On Nov. 17, 2026, the S&P 500 closed at 7,340.53, just 0.05% below its 200-day moving average, according to AInvest’s calculations using Yahoo Finance closing data. The total-return index, which includes reinvested dividends, finished 0.36% above its own average. A trading rule that held stocks above the line and sold below it would have given opposite signals depending on which index it tracked.
AInvest tested the rule on the total-return index over 9,288 trading days, from January 1990 through Nov. 17, 2026. The strategy spent 77% of the time in stocks and returned 9.9% a year before tax, compared with 10.7% for buy-and-hold. What it gave up in return, it partly made up for in protection: its worst peak-to-trough loss was 20.6%, against 55.3% for the index.
A slower signal worked better in prolonged declines
The 200-day simple moving average gives equal weight to the past 200 daily closes. A free TradingView script displays it alongside three faster, exponential averages that give more weight to recent prices. Putting the daily average on a one-minute chart does not make it more responsive: there is still only one new closing observation per day.
In the backtest, the strategy acted on each signal at the next day’s close and earned the 13-week Treasury bill rate while out of stocks. The results exclude fund fees and trading spreads.
| Strategy | Annual return before tax | Worst peak-to-trough loss | Modeled annual return after tax |
|---|---|---|---|
| 20-day simple average | 5.2% | 40.5% | 1.4% |
| 50-day simple average | 6.3% | 35.4% | 3.3% |
| 9-/21-day exponential crossover | 6.6% | 29.4% | 3.7% |
| 100-day simple average | 7.6% | 46.7% | 4.8% |
| 200-day simple average | 9.9% | 20.6% | 7.3% |
| Buy-and-hold | 10.7% | 55.3% | 9.9% |
The 200-day rule’s advantage was clearest in the 2000s: it earned 5.4% a year while the index lost 0.9% a year. But a rule that waits for prices to confirm a recovery can miss much of a fast rebound. From Feb. 27 to May 26, 2020, the strategy sold near the bottom and bought back at a higher price. It lost 6.05% over that stretch while the index gained 0.95%.
Over the full test, the 200-day strategy earned more per unit of volatility, with a Sharpe ratio of 0.64 versus 0.51 for buy-and-hold. In dollar terms, however, an initial $10,000 grew to about $326,000 before tax, against $427,000 for holding the index.
Frequent trades widened the after-tax gap
Small moves near the average accounted for most of the trading: 71% of switches occurred within 1% of the line, and 95% within 2%. Of 106 completed round trips, 97 lasted less than a year. The median holding period was seven days.
Selling brings forward the tax on realized gains, while a buy-and-hold investor can defer that tax until the final sale. Using a 23.8% federal rate, AInvest estimated annual after-tax returns of 7.3% for the rule and 9.9% for buy-and-hold with a sale at the end. The model used the 20% long-term capital-gains rate plus the 3.8% net investment income tax. It did not account for state taxes or the ordinary income rates applicable to short-term gains.
Checking less often narrowed the gap. In a separate month-end test, a 12-month average generated just 19 round trips in 37 years. It returned 10.7% a year before tax versus 11.0% for buy-and-hold in that comparison, with a worst loss of 16.7%. After tax, the figures were 8.4% and 10.2%. In both tests, the historical case for the slower trading rule was a smaller loss along the way, not a larger balance at the end.




