QQQ (Invesco QQQ Trust) SMA(50)/SMA(200) crossover strategy

Backtest a QQQ (Invesco QQQ Trust) crossover strategy: it buys when 50-day SMA crosses above 200-day SMA, it sells when 50-day SMA falls below 200-day SMA. No leverage applied. Uninvested cash earns 4.0% risk-free interest.

Backtest Assumptions and Key Details

  • If the strategy involves regular stock positions, we use the adjusted close price for backtesting. This reflects total return by incorporating dividends.
  • If the strategy uses call options to simulate leveraged exposure, we instead use the close price (not adjusted), because dividends are not received when holding options.
  • When using call options, we simulate time decay in a simplified way. You can specify a time decay rate (e.g., 3%), which means that if the stock price stays flat for one year, the strategy loses 3% of the current stock price per share of exposure due to decay.
  • If leverage is applied via margin borrowing, we enforce a 25% maintenance margin requirement (as set by FINRA). This places a hard cap at 4x leverage, beyond which a margin call is immediate. In practice, 3x leverage is the more realistic limit, since the risk of a margin call increases sharply beyond that.
  • All trades are assumed to execute at the closing price on the day a signal occurs.
  • The backtest includes realistic cash flow effects, such as interest earned on idle cash and borrowing costs incurred when using margin.

Performance Overview

Portfolio Value Trend (Normalized)

1999-03-10 - $10,000.00 2025-07-05 - $307,898.83

Over 26.32 years, portfolio value grew from $10,000.00 to $307,898.83.

Beginning with an initial investment of $10,000.00 on 1999-03-10, the portfolio value reached a value of $307,898.83 by 2025-07-05. This represents a 2,978.99% total gain over 26.32 years, equivalent to 13.91% annualized. This return is moderately above long-term averages. It reflects solid long-term performance and an effective strategy.

Drawdown and Risk

The maximum drawdown recorded during this period was 36.47%. This drawdown began after a peak portfolio value of $22,232.98 on 2000-03-27, and reached its lowest point on 2000-05-23 when the portfolio value fell to $14,125.72. The drawdown lasted for 57 days.

Maximum Drawdown

๐Ÿ“ˆ 2000-03-27 - $22,232.98 ๐Ÿ“‰ 2000-05-23 - $14,125.72

Max drawdown: 36.47% over 57 days.

The drawdown was moderate and aligns with the type of volatility observed in many broad market assets over extended periods. The maximum drawdown lasted over a month, which is fairly common during pullbacks or short-term volatility spikes.

The Calmar Ratio โ€” annualized return divided by maximum drawdown โ€” was 0.38, reflecting the tradeoff between return and volatility. A moderate return-to-risk profile. The strategy handled risk reasonably well while delivering decent returns.

What the Strategy Suggests Today

The 50-day SMA is $515.59, and the 200-day SMA is $503.23, for a difference of $12.36. The current stock price is $556.22, and 0.0% of that is $0.00. Since the difference is sufficient and exceeds the threshold, the buy signal is active.

The 50-day SMA is $515.59, and the 200-day SMA is $503.23, for a difference of $12.36. The current stock price is $556.22, and 0.0% of that is $0.00. Since the difference is insufficient and does not exceed the threshold, the sell signal is not active.

If you have been following this strategy, you are currently holding stocks or call options. No sell signal is active. The strategy suggests continuing to hold the current position.

Transaction Timeline

We began our backtest on 1999-03-10 with $10,000.00 starting capital.

On 1999-05-20, the 50-day SMA at $53.25 crossed above the 200-day SMA at $53.21, exceeding it by 0% of the stock price ($53.37). Since we can receive dividends, we use the adjusted close price($45.19) for calculation. We invested $10,076.53 โ€” which includes $76.53 in interest earned while holding cash for 71 days โ€” gaining exposure to 223.00 equivalent shares.

On 2000-09-22, the 50-day SMA at $94.62 fell below the 200-day SMA at $94.76 by 0% of the stock price ($92.94), triggering our exit. Since we can receive dividends, we use the adjusted close price($78.69) for calculation. After holding the position for 491 days, we exited leaving $17,548.01 in available cash.

On 2003-01-24, the 50-day SMA at $26.07 crossed above the 200-day SMA at $26.05, exceeding it by 0% of the stock price ($24.82). Since we can receive dividends, we use the adjusted close price($21.01) for calculation. We invested $19,233.34 โ€” which includes $1,685.33 in interest earned while holding cash for 854 days โ€” gaining exposure to 915.22 equivalent shares.

On 2003-02-12, the 50-day SMA at $25.44 fell below the 200-day SMA at $25.46 by 0% of the stock price ($23.82), triggering our exit. Since we can receive dividends, we use the adjusted close price($20.17) for calculation. After holding the position for 19 days, we exited leaving $18,458.42 in available cash.

On 2003-03-03, the 50-day SMA at $25.12 crossed above the 200-day SMA at $25.10, exceeding it by 0% of the stock price ($24.65). Since we can receive dividends, we use the adjusted close price($20.87) for calculation. We invested $18,496.12 โ€” which includes $37.70 in interest earned while holding cash for 19 days โ€” gaining exposure to 886.21 equivalent shares.

On 2004-07-21, the 50-day SMA at $35.97 fell below the 200-day SMA at $35.98 by 0% of the stock price ($34.40), triggering our exit. Since we can receive dividends, we use the adjusted close price($29.14) for calculation. After holding the position for 506 days, we exited leaving $25,822.12 in available cash.

On 2004-11-09, the 50-day SMA at $35.78 crossed above the 200-day SMA at $35.73, exceeding it by 0% of the stock price ($37.92). Since we can receive dividends, we use the adjusted close price($32.12) for calculation. We invested $26,131.75 โ€” which includes $309.63 in interest earned while holding cash for 111 days โ€” gaining exposure to 813.59 equivalent shares.

On 2005-04-26, the 50-day SMA at $36.65 fell below the 200-day SMA at $36.67 by 0% of the stock price ($35.05), triggering our exit. Since we can receive dividends, we use the adjusted close price($29.97) for calculation. After holding the position for 168 days, we exited leaving $24,385.29 in available cash.

On 2005-07-18, the 50-day SMA at $37.50 crossed above the 200-day SMA at $37.47, exceeding it by 0% of the stock price ($38.73). Since we can receive dividends, we use the adjusted close price($33.15) for calculation. We invested $24,603.61 โ€” which includes $218.31 in interest earned while holding cash for 83 days โ€” gaining exposure to 742.19 equivalent shares.

On 2006-06-14, the 50-day SMA at $40.58 fell below the 200-day SMA at $40.59 by 0% of the stock price ($37.63), triggering our exit. Since we can receive dividends, we use the adjusted close price($32.31) for calculation. After holding the position for 331 days, we exited leaving $23,979.31 in available cash.

On 2006-10-24, the 50-day SMA at $40.13 crossed above the 200-day SMA at $40.03, exceeding it by 0% of the stock price ($42.14). Since we can receive dividends, we use the adjusted close price($36.23) for calculation. We invested $24,321.62 โ€” which includes $342.32 in interest earned while holding cash for 132 days โ€” gaining exposure to 671.38 equivalent shares.

On 2008-02-01, the 50-day SMA at $49.00 fell below the 200-day SMA at $49.01 by 0% of the stock price ($45.59), triggering our exit. Since we can receive dividends, we use the adjusted close price($39.36) for calculation. After holding the position for 465 days, we exited leaving $26,423.33 in available cash.

On 2008-06-25, the 50-day SMA at $48.28 crossed above the 200-day SMA at $48.25, exceeding it by 0% of the stock price ($47.57). Since we can receive dividends, we use the adjusted close price($41.13) for calculation. We invested $26,837.98 โ€” which includes $414.64 in interest earned while holding cash for 145 days โ€” gaining exposure to 652.57 equivalent shares.

On 2008-07-09, the 50-day SMA at $48.04 fell below the 200-day SMA at $48.06 by 0% of the stock price ($44.75), triggering our exit. Since we can receive dividends, we use the adjusted close price($38.69) for calculation. After holding the position for 14 days, we exited leaving $25,246.99 in available cash.

On 2009-06-01, the 50-day SMA at $33.07 crossed above the 200-day SMA at $33.00, exceeding it by 0% of the stock price ($36.39). Since we can receive dividends, we use the adjusted close price($31.58) for calculation. We invested $26,149.26 โ€” which includes $902.27 in interest earned while holding cash for 327 days โ€” gaining exposure to 828.03 equivalent shares.

On 2010-07-21, the 50-day SMA at $45.31 fell below the 200-day SMA at $45.38 by 0% of the stock price ($44.64), triggering our exit. Since we can receive dividends, we use the adjusted close price($39.08) for calculation. After holding the position for 415 days, we exited leaving $32,360.75 in available cash.

On 2010-09-28, the 50-day SMA at $46.20 crossed above the 200-day SMA at $46.13, exceeding it by 0% of the stock price ($49.37). Since we can receive dividends, we use the adjusted close price($43.32) for calculation. We invested $32,601.41 โ€” which includes $240.66 in interest earned while holding cash for 69 days โ€” gaining exposure to 752.50 equivalent shares.

On 2011-08-17, the 50-day SMA at $56.12 fell below the 200-day SMA at $56.15 by 0% of the stock price ($53.58), triggering our exit. Since we can receive dividends, we use the adjusted close price($47.28) for calculation. After holding the position for 323 days, we exited leaving $35,581.27 in available cash.

On 2011-12-08, the 50-day SMA at $56.28 crossed above the 200-day SMA at $56.26, exceeding it by 0% of the stock price ($56.12). Since we can receive dividends, we use the adjusted close price($49.62) for calculation. We invested $36,015.65 โ€” which includes $434.38 in interest earned while holding cash for 113 days โ€” gaining exposure to 725.87 equivalent shares.

On 2012-12-13, the 50-day SMA at $65.58 fell below the 200-day SMA at $65.59 by 0% of the stock price ($65.31), triggering our exit. Since we can receive dividends, we use the adjusted close price($58.36) for calculation. After holding the position for 371 days, we exited leaving $42,362.60 in available cash.

On 2013-01-28, the 50-day SMA at $65.64 crossed above the 200-day SMA at $65.58, exceeding it by 0% of the stock price ($67.15). Since we can receive dividends, we use the adjusted close price($60.34) for calculation. We invested $42,572.37 โ€” which includes $209.77 in interest earned while holding cash for 46 days โ€” gaining exposure to 705.55 equivalent shares.

On 2015-09-30, the 50-day SMA at $106.84 fell below the 200-day SMA at $106.88 by 0% of the stock price ($101.76), triggering our exit. Since we can receive dividends, we use the adjusted close price($94.59) for calculation. After holding the position for 975 days, we exited leaving $66,737.28 in available cash.

On 2015-11-17, the 50-day SMA at $108.20 crossed above the 200-day SMA at $108.16, exceeding it by 0% of the stock price ($111.49). Since we can receive dividends, we use the adjusted close price($103.63) for calculation. We invested $67,082.15 โ€” which includes $344.88 in interest earned while holding cash for 48 days โ€” gaining exposure to 647.30 equivalent shares.

On 2016-02-04, the 50-day SMA at $108.71 fell below the 200-day SMA at $108.76 by 0% of the stock price ($101.65), triggering our exit. Since we can receive dividends, we use the adjusted close price($94.78) for calculation. After holding the position for 79 days, we exited leaving $61,348.35 in available cash.

On 2016-05-09, the 50-day SMA at $107.66 crossed above the 200-day SMA at $107.61, exceeding it by 0% of the stock price ($105.88). Since we can receive dividends, we use the adjusted close price($99.01) for calculation. We invested $61,977.39 โ€” which includes $629.04 in interest earned while holding cash for 95 days โ€” gaining exposure to 625.95 equivalent shares.

On 2016-06-28, the 50-day SMA at $107.64 fell below the 200-day SMA at $107.64 by 0% of the stock price ($104.46), triggering our exit. Since we can receive dividends, we use the adjusted close price($97.94) for calculation. After holding the position for 50 days, we exited leaving $61,309.06 in available cash.

On 2016-07-15, the 50-day SMA at $108.01 crossed above the 200-day SMA at $107.95, exceeding it by 0% of the stock price ($111.80). Since we can receive dividends, we use the adjusted close price($104.83) for calculation. We invested $61,421.08 โ€” which includes $112.02 in interest earned while holding cash for 17 days โ€” gaining exposure to 585.93 equivalent shares.

On 2018-12-03, the 50-day SMA at $172.45 fell below the 200-day SMA at $172.49 by 0% of the stock price ($172.33), triggering our exit. Since we can receive dividends, we use the adjusted close price($164.86) for calculation. After holding the position for 871 days, we exited leaving $96,596.14 in available cash.

On 2019-04-02, the 50-day SMA at $172.82 crossed above the 200-day SMA at $172.81, exceeding it by 0% of the stock price ($182.73). Since we can receive dividends, we use the adjusted close price($175.63) for calculation. We invested $97,848.92 โ€” which includes $1,252.78 in interest earned while holding cash for 120 days โ€” gaining exposure to 557.14 equivalent shares.

On 2020-04-29, the 50-day SMA at $201.27 fell below the 200-day SMA at $201.27 by 0% of the stock price ($219.00), triggering our exit. Since we can receive dividends, we use the adjusted close price($212.29) for calculation. After holding the position for 393 days, we exited leaving $118,274.05 in available cash.

On 2020-05-21, the 50-day SMA at $203.96 crossed above the 200-day SMA at $203.76, exceeding it by 0% of the stock price ($228.87). Since we can receive dividends, we use the adjusted close price($221.86) for calculation. We invested $118,553.79 โ€” which includes $279.74 in interest earned while holding cash for 22 days โ€” gaining exposure to 534.37 equivalent shares.

On 2022-03-01, the 50-day SMA at $367.56 fell below the 200-day SMA at $367.69 by 0% of the stock price ($341.49), triggering our exit. Since we can receive dividends, we use the adjusted close price($333.80) for calculation. After holding the position for 649 days, we exited leaving $178,374.50 in available cash.

On 2023-03-13, the 50-day SMA at $290.18 crossed above the 200-day SMA at $290.11, exceeding it by 0% of the stock price ($290.69). Since we can receive dividends, we use the adjusted close price($286.24) for calculation. We invested $185,743.84 โ€” which includes $7,369.34 in interest earned while holding cash for 377 days โ€” gaining exposure to 648.91 equivalent shares.

On 2025-04-14, the 50-day SMA at $491.92 fell below the 200-day SMA at $492.94 by 0% of the stock price ($457.48), triggering our exit. Since we can receive dividends, we use the adjusted close price($456.97) for calculation. After holding the position for 763 days, we exited leaving $296,528.97 in available cash.

On 2025-06-24, the 50-day SMA at $501.48 crossed above the 200-day SMA at $500.23, exceeding it by 0% of the stock price ($539.78). Since we can receive dividends, we use the adjusted close price($539.78) for calculation. We invested $298,798.40 โ€” which includes $2,269.43 in interest earned while holding cash for 71 days โ€” gaining exposure to 553.56 equivalent shares.

As of 2025-07-05, we hold 553.56 shares without leverage. The net liquidation value of $307,898.83 reflects proceeds after repaying all borrowed funds and interest.