SPY Moon Phase Equity Backtest

Should the moon phase influence your trading? What about the position of Jupiter? Technical analysis?

There is a finance-oriented Discord bot called “Alpha.” Among its features is the ability to generate a chart of your desired ticker with the moon phase overlaid.

Discord command: /c arguments: spx 1d moon wide log
In this post we’ll take a look at the backtest results of using the moon phase to open (or not) a long and/or short SPY position each trading day from Jan 3 2007 through Jul 27 2022 and see if there are any discernible trends.
Theses:
- if we open and hold a long SPY position only on the days in which the moon phase becomes “Full Moon” till the day before a “New Moon” happens, we will outperform a buy and hold SPY portfolio with regard to PnL, sharpe, and max drawdown. On the day the moon phase changes to “New Moon”, close any long SPY position and go to cash.
- if we open and hold a short SPY position only on the days in which the moon phase becomes “New Moon” till the day before a “Full Moon” happens, we will outperform a buy and hold SPY portfolio with regard to PnL, sharpe, and max drawdown. On the day when the moon phase changes to “Full Moon”, close any short SPY position and go to cash.
- if we combine the first two ideas, we will outperform either idea on its own with regard to PnL, sharpe and max drawdown
- we will also explore the reverse of the above mechanics. That is, going long when the moon phase becomes “New Moon”, short when the moon phase becomes “Full Moon”, etc.
To test these theses we will:
- Review the moon phase each morning before market open.
- If moon phase = “Full Moon”, open a long SPY position at market open and hold this position until the next morning.
- If moon phase = “New Moon”, if there’s an existing long position, close it at market open. Otherwise, take no action.
- Review the moon phase each morning before market open.
- If moon phase = “New Moon”, open a short SPY position at market open and hold this position until the next morning.
- If moon phase = “Full Moon”, if there’s an existing short position, close it at market open. Otherwise, take no action.
- Review the moon phase each morning before market open.
- If moon phase = “Full Moon”, if there’s an existing short position, close it at market open and open a long SPY position.
- If moon phase = “New Moon”, if there’s an existing long position, close it at market open and open a short SPY position.
- Review the moon phase each morning before market open.
- If moon phase = “New Moon”, open a long SPY position at market open and hold this position until the next morning.
- etc…

Due to the nature of celestial events, the experience of someone at one location on Earth can be different than someone elsewhere on the planet. We’ll need to anchor times and timezones in order to make the study universal and repeatable.
Historical moon phase data is from: http://astropixels.com/ephemeris/phasescat/phases2001.html. All dates/times were adjusted by -5 (minus five) hours to adjust from “universal time” (UT) to Eastern Standard Time (EST). Times are not adjusted for DST when applicable, latitude differences or refraction. Dates are based on the Gregorian calendar.
If a new moon occurs at any time on a given date, the entire date is defined as a new moon. For example, if a new moon happens at 8:29pm on a Tuesday, the entire day will be considered a “new moon” day. The same applies for full moon events. Because the moon phase can be forecast with ample accuracy, there is no bias in this methodology; we know ahead of time what the moon phase will be for the day by the time the market opens.
All this talk about moon phases is fine and dandy but an astrology-based strategy in isolation isn’t helpful. Let’s compare it against the following benchmark and see how it performs:
- SPY buy/hold (total return) | 100% allocation, no leverage
There are 6 backtests in this study evaluating over 15,600 SPY equity trades.
Let’s dive in!
Contents
Summary
Thesis 1: opening and maintaining a long SPY position only on the days in which the moon phase is “Full Moon”, and on days when the moon phase is “New Moon”, closing any long SPY position and going to cash underperformed a buy-and-hold SPY portfolio with regard to:
- Total PnL
- Sharpe Ratio
- Max Drawdown
- Max Drawdown Duration
Thesis 2: opening and maintaining a short SPY position only on the days in which the moon phase is “New Moon”, and on days when the moon phase is “Full Moon”, closing any long SPY position and going to cash underperformed a buy-and-hold SPY portfolio with regard to:
- Total PnL
- Sharpe Ratio
- Max Drawdown
- Max Drawdown Duration
Thesis 3: closing any short SPY position and opening and maintaining a long SPY position only on the days in which the moon phase is “Full Moon”, and on days when the moon phase is “New Moon”, closing any long SPY position and opening and maintaining a short SPY position underperformed a buy-and-hold SPY portfolio with regard to:
- Total PnL
- Sharpe Ratio
- Annualized Volatility
- Max Drawdown
- Max Drawdown Duration
Thesis 4: opening and maintaining a long SPY position only on the days in which the moon phase is “New Moon”, and on days when the moon phase is “Full Moon”, closing any long SPY position and going to cash outperformed a buy-and-hold SPY portfolio with regard to:
- Total PnL
- Sharpe Ratio
- Annualized Volatility
- Max Drawdown
- Max Drawdown Duration
- Capital Efficiency: 117% | 2.2x improvement
Thesis 5: opening and maintaining a short SPY position only on the days in which the moon phase is “Full Moon”, and on days when the moon phase is “New Moon”, closing any long SPY position and going to cash underperformed a buy-and-hold SPY portfolio with regard to:
- Total PnL
- Sharpe Ratio
- Max Drawdown Duration
Thesis 6: closing any short SPY position and opening and maintaining a long SPY position only on the days in which the moon phase is “New Moon”, and on days when the moon phase is “Full Moon”, closing any long SPY position and opening and maintaining a short SPY position outperformed a buy-and-hold SPY portfolio with regard to:
- Total PnL
- Max Drawdown
- Max Drawdown Duration
Methodology
Strategy Details
- Symbol: SPY (price return; not total return)
- Strategy: Long/Short Equity
- Days Till Expiration: N/A
- Start Date: 2007-01-03
- End Date: 2022-07-27
- Positions opened per trade: 1
- Entry Days: each trading day in which moon phase = Full Moon
- Entry Signal: moon phase
- Timing: 9:30am ET
- Strike Selection: N/A
- Trade Entry Delta: N/A
- Trade Exit: moon phase
- Max Margin Utilization Target (short option strats only): N/A | 1x leverage
- Max Drawdown Target: 99% | account value shall not go negative
Assumptions
- Margin requirements are always satisfied
- Margin calls never occur
- Margin requirement for short CALL and PUT positions is 20% of notional
- Margin requirement for short STRADDLE and STRANGLE positions is 20% of the larger strike
- Margin requirement for short VERTICAL SPREAD positions is the difference between the strikes
- Margin requirement for short CALENDAR SPREAD positions is 20% of the short option (short option expires after the long option)
- Margin requirement for long CALENDAR SPREAD positions is the net cost of the spread (short option expires before the long option)
- Early assignment never occurs
- There is ample liquidity at all times
Mechanics
- Prices are in USD
- Prices are nominal (not adjusted for inflation)
- All statistics are pre-tax, where applicable
- Margin collateral is invested in 3mo US treasuries and earns interest daily
- Assignment P/L is calculated by closing the ITM position at 3:46pm ET the day of position exit if managed early or 4:00pm if held till expiration
- Commission to open, close early, or expire ITM is 1.00 USD per non-index underlying (eg: SPY, AAPL, etc.) contract
- Commission to open, close early, or expire ITM is 1.32 USD per index underlying (eg: SPX) contract
- Commission to expire worthless is 0.00 USD per contract (non-index and index)
- Commission to open or close non-option positions, if applicable, is 0.00 USD
- Slippage is calculated according to the slippage table
- Starting capital for short option backtests is adjusted in $1000 increments such that max margin utilization is between 80-100%, closest to 100%, of max margin utilization target
- Starting capital for long option backtests is adjusted in $1000 increments such that max drawdown is between 80-100%, closest to 100%, of max drawdown target
- Positions that have an exit date beyond the backtest end date are excluded
- For comprehensive details, visit the methodology page
Results
Starting Capital and Leverage

Starting capital was held constant across all strategies.
Win Rate Stats

Opening long SPY positions produced more winning trades than opening short SPY positions.
Profit and Loss Stats
An active subscription is needed to view this content. Already a subscriber? Log in. Not a subscriber? Sign up for just 99 USD a year. Learn more.
Performance Stats
An active subscription is needed to view this content. Already a subscriber? Log in. Not a subscriber? Sign up for just 99 USD a year. Learn more.
Risk Management
An active subscription is needed to view this content. Already a subscriber? Log in. Not a subscriber? Sign up for just 99 USD a year. Learn more.
Overall

Trading by moon phase generally underperformed buy-and-hold with regard to total return and lost money overall. Initiating / maintaining a long SPY position during the new moon phase was an exception. However, for roughly two years from 2016-2018, the “new moon long SPY” strat experienced a material underperformance.
Discussion
This study is a prime example of a spurious correlation. We can add “the profitability of market timing the S&P index with the ‘new moon’ phase” to Tyler’s Spurious Correlations website.
Additional Resources
Custom Backtests
Have your ideas professionally backtested for as little at 99 USD. Learn more.
- trade ideas remain confidential
- backtest results remain unpublished
- deliverables include:
- a master-results spreadsheet
- raw trade logs and data sources
- most custom research is completed within 5 business days
Contact me for a quote.
Trade Logs
Visit the trade log store to download the trade logs associated with this and other published studies.
s1 signal
Trade S&P 500 options with 4.2x greater risk-adjusted return using the s1 signal. Learn more.
s2 signal
Trade GLD options with 2.4x greater risk-adjusted return using the s2 signal. Learn more.
mREIT Dashboard
Using low-beta alternatives to cash or treasury holdings for margin collateral can boost portfolio risk-adjusted and total returns. Learn more.
One-on-One Consults
Ask questions, brainstorm ideas or simply pick my brain. Option strategy reviews, portfolio performance tuning, tax arbitrage, and more. Book a session today.
Data Used in Study
This strategy uses historical SPY data from Yahoo! Finance.
July 29, 2022 @ 10:07 am
Haha!
July 29, 2022 @ 12:03 pm
You have way too much time on your hands.
August 3, 2022 @ 9:22 pm
Glad you guys enjoyed it 🙂