Learn › Strategies › SMA 10/50 Trend › XLP

SMA 10/50 Trend on XLP

Consumer Staples Select Sector SPDR Fund: defensive consumer staples, a common risk-off equity sector. Backtest 2021-01-04 to 2026-10-02, $10,000 starting capital, computed by the same engine that runs live DeployQuant strategies.

Result: SMA 10/50 trend on XLP turned $10,000 into $10,714 (7.1% total, 1.2% CAGR): it trailed buy-and-hold by 4.6% per year, with a maximum drawdown 0.4 points shallower than holding (15.6% vs 16.0%).
1.2%CAGR
5.8%buy & hold CAGR
−15.6%max drawdown
0.17Sharpe ratio
19round trips
37%win rate
■ SMA 10/50 trend   ■ buy & hold, $10,000 invested 2021-01-04

Year by year

YearSMA 10/50 trendbuy & hold
202114.5%18.1%
2022−4.7%−0.7%
2023−3.8%−0.9%
20247.6%12.0%
2025−8.3%1.5%
20263.5%5.6%

Month by month

YearJanFebMarAprMayJunJulAugSepOctNovDec
20210.0%0.0%3.5%1.9%1.7%−1.7%0.5%1.1%−1.9%0.2%−1.4%10.3%
2022−1.4%−0.1%−0.4%2.4%−8.4%0.0%1.9%−1.8%−0.2%0.0%6.6%−2.6%
2023−2.8%0.0%1.1%3.6%−5.6%0.0%0.3%−3.8%0.0%0.0%1.1%2.6%
20241.2%2.0%3.2%−4.1%2.3%−0.2%1.6%5.8%1.2%−1.1%0.0%−4.2%
20250.0%3.7%−3.9%−3.1%1.2%−2.1%−1.3%−2.0%−0.1%0.0%0.0%−0.8%
20267.3%7.6%−7.9%0.0%−1.2%−1.9%2.3%−0.1%−1.8%0.0%––

Every trade

SMA 10/50 trend on XLP made 19 closed round trips, an average hold of 67 days, an average winner of 5.17%, an average loser of −2.28%, a profit factor of 1.24, a longest losing streak of 3. It held a position at the close on 59.9% of trading days.

EntryEntry priceExitExit priceReturnDays held
2021-03-18$56.992021-06-23$60.145.5%97
2021-07-16$61.872021-09-23$61.69−0.3%69
2021-10-28$62.272022-02-18$66.947.5%113
2022-03-31$67.412022-05-19$62.85−6.8%49
2022-07-18$65.232022-09-08$65.12−0.2%52
2022-11-02$64.992023-01-19$65.580.9%78
2023-03-29$67.172023-05-30$66.38−1.2%62
2023-07-21$69.152023-08-21$66.63−3.6%31
2023-11-16$64.392024-04-16$68.576.5%152
2024-04-30$70.802024-10-16$77.849.9%169
2024-12-02$78.742024-12-24$75.31−4.4%22
2025-02-12$76.382025-03-25$76.09−0.4%41
2025-04-03$78.872025-04-08$75.46−4.3%5
2025-04-24$77.622025-06-23$77.820.3%60
2025-07-07$79.342025-07-21$78.26−1.4%14
2025-08-12$79.732025-09-04$78.04−2.1%23
2025-12-03$76.892026-03-19$81.185.6%106
2026-05-07$82.802026-06-09$81.96−1.0%33
2026-06-15$84.362026-09-10$82.84−1.8%87

Prices are adjusted for splits and dividends, so they sit below the quotes printed at the time. An open position is marked at the last close.

Largest drawdowns

PeakLow pointDepthDays to lowRecoveredDays to recover
2022-04-202023-11-20−15.6%5792024-09-09294
2024-09-162026-01-07−15.1%478not yet–
2021-06-042021-12-01−4.5%1802021-12-109

Buy-and-hold's deepest drawdown ran from 2022-04-20 to 2022-10-07 and reached −16.0%.

With trading costs

The headline run fills at the bar price. These runs charge slippage on every fill.

Slippage per fillCAGRMax drawdownFinal valueSharpe
None (headline)1.2%−15.6%$10,7140.17
5 basis points0.9%−16.1%$10,5160.14
10 basis points0.5%−16.5%$10,3160.10

Changing the parameters

VersionCAGRMax drawdownRound tripsWin rateFinal value
Published rules1.2%−15.6%1937%$10,714
SMA 5/50−0.1%−20.2%2540%$9,927
SMA 20/50−0.3%−19.7%1839%$9,858
SMA 10/100−0.7%−22.6%1631%$9,624

How XLP behaved

MeasureXLP
Data in this test2021-01-04 to 2026-10-02 (1444 sessions)
Total return, buy and hold40.3%
Annualized volatility13.3%
Deepest drawdown−16.3% (2022-04-20 to 2022-10-07)
Up days51.6%
Average daily range1.12%
Average overnight gap0.29%
Correlation to SPY0.47
Correlation to QQQ0.30
Correlation to TLT0.13
Sessions above the 200-day average75.1%
Crossings of the 200-day average73
Falls of 10% or more from a 20-day high1

The rules

A faster moving-average crossover: hold while the 10-day average is above the 50-day.

  1. WHEN the market opens · IF not invested AND SMA(10) > SMA(50) · THEN buy with 98% of the sleeve
  2. WHEN the market opens · IF invested AND SMA(10) < SMA(50) · THEN sell the whole position

A faster version of the golden cross. The 10- and 50-day averages catch intermediate trends measured in weeks rather than years. It enters recoveries earlier and exits breakdowns earlier, with more whipsaw trades in sideways markets. Useful for seeing how signal speed changes a strategy's results.

Good for: trending assets with multi-week swings, such as leveraged index ETFs.
Watch out: several false signals a year is normal; each whipsaw costs a small loss and they add up in flat markets.

Run SMA 10/50 trend on XLP yourself, free →

Build it from blocks (or type it in English), backtest it on 5.7 years of minute data in seconds, tweak any parameter, then paper trade it on live data. No card, no broker needed to start.

Frequently asked questions

Did SMA 10/50 trend beat buy-and-hold on XLP?

Over 2021-01-04 to 2026-10-02, SMA 10/50 trend on XLP returned 1.2% annualized vs 5.8% for buy-and-hold: it trailed buy-and-hold by 4.6% per year, with a maximum drawdown 0.4 points shallower than holding (15.6% vs 16.0%).

How many trades did it make?

19 completed round trips over 5.7 years (38 fills), with 37% of round trips closing profitably.

Why 10 and 50 days?

A common intermediate-trend pairing. It reacts within weeks and ignores single bad days. Both windows are editable parameters in DeployQuant.

Related

SMA 10/50 Trend on all 59 ETFsfull results table All strategies on XLP12 templates compared RSI(14) Mean Reversion on XLPsame ETF, different rulesRSI(2) Dip Snapback on XLPsame ETF, different rules

Backtests are hypothetical, computed by DeployQuant's engine on minute-resolution consolidated US market data (2021-01-04 to 2026-10-02, $10,000 starting capital, no margin, no fees or slippage in the headline run; buy-and-hold puts 98% of the account in at the first open, as the templates do) and do not guarantee future results. Nothing on this page is investment advice. Live trading involves risk of loss.