Learn › Strategies › Golden Cross (SMA 50/200) › XLP

Golden Cross (SMA 50/200) 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: golden cross on XLP turned $10,000 into $11,236 (12.4% total, 2.0% CAGR): it trailed buy-and-hold by 3.8% per year, with a maximum drawdown 1.7 points shallower than holding (14.3% vs 16.0%).
2.0%CAGR
5.8%buy & hold CAGR
−14.3%max drawdown
0.24Sharpe ratio
3round trips
67%win rate
■ golden cross   ■ buy & hold, $10,000 invested 2021-01-04

Year by year

Yeargolden crossbuy & hold
202110.3%18.1%
2022−4.1%−0.7%
2023−3.6%−0.9%
20249.5%12.0%
20253.2%1.5%
2026−2.5%5.6%

Month by month

YearJanFebMarAprMayJunJulAugSepOctNovDec
20210.0%0.0%0.0%0.0%0.0%0.0%0.0%0.0%0.0%1.4%−1.4%10.3%
2022−1.4%−1.3%1.5%2.5%−4.0%−2.3%1.1%0.0%0.0%0.0%0.0%0.0%
2023−1.1%−2.3%4.1%3.6%−6.0%2.7%2.0%−3.9%−2.4%0.0%0.0%0.0%
20240.0%1.0%3.3%−1.0%2.3%−0.2%1.6%5.9%1.2%−3.5%3.8%−4.7%
20250.5%5.0%−1.1%0.2%1.2%−1.6%−1.4%1.3%−2.3%1.6%0.0%0.0%
20260.0%6.7%−8.2%2.8%−1.6%0.9%2.3%−0.1%−4.4%−0.1%––

Every trade

golden cross on XLP made 3 closed round trips and one position still open at the end of the test, an average hold of 389 days, an average winner of 9.59%, an average loser of −3.69%, a profit factor of 5.00, a longest losing streak of 1. It held a position at the close on 67.0% of trading days.

EntryEntry priceExitExit priceReturnDays held
2021-10-19$61.522022-07-12$65.155.9%266
2022-12-21$67.472023-09-22$64.98−3.7%275
2024-02-06$68.442025-10-23$77.5313.3%625
2026-02-03$82.66open–−2.5%–

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-202022-06-17−14.3%582024-08-27802
2026-02-272026-03-20−9.4%21not yet–
2024-09-162025-01-15−8.2%1212025-02-2541

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)2.0%−14.3%$11,2360.24
5 basis points2.0%−14.3%$11,1910.23
10 basis points1.9%−14.3%$11,1570.23

Changing the parameters

VersionCAGRMax drawdownRound tripsWin rateFinal value
Published rules2.0%−14.3%367%$11,236
SMA 40/2000.2%−19.8%540%$10,140
SMA 50/1501.5%−14.6%450%$10,897
SMA 60/250−3.1%−23.2%425%$8,357

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

Hold while the 50-day average is above the 200-day; step aside when it crosses below (the death cross).

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

A widely used trend filter. When the 50-day simple moving average is above the 200-day, the asset is in a long-term uptrend and the strategy holds. When it crosses below, the strategy moves to cash. It trades rarely, with a handful of signals per decade on an index. Its use is skipping the deepest bear markets, and it will lag some rallies.

Good for: long-horizon investors who want to hold trends but sidestep multi-year bear markets.
Watch out: crosses lag at turning points: the strategy gives back the first leg of a crash and misses the first leg of a recovery, and choppy sideways markets whipsaw it.

Run golden cross 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 golden cross beat buy-and-hold on XLP?

Over 2021-01-04 to 2026-10-02, golden cross on XLP returned 2.0% annualized vs 5.8% for buy-and-hold: it trailed buy-and-hold by 3.8% per year, with a maximum drawdown 1.7 points shallower than holding (14.3% vs 16.0%).

How many trades did it make?

3 completed round trips over 5.7 years (7 fills), with 67% of round trips closing profitably.

How often does a golden cross happen?

On a broad index, roughly every couple of years. The backtest pages show the exact trade count for each ETF over the 2021 to 2026 window.

Golden cross vs buy and hold: which does better?

It depends on the asset and the window. Every backtest page here shows the same-window buy-and-hold comparison.

Related

Golden Cross (SMA 50/200) 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.