Academic research has documented persistent calendar effects in stock market returns. The question is whether they are reliable enough to act on — and for most investors, the answer is no.
The End-of-Month Effect
Studies by CMG Capital Management Group and others have shown that a majority of S&P 500 returns in any given month tend to occur in the last 5–6 trading days. The "last trading day effect" and "turn-of-the-month effect" have been documented across multiple decades. Hypothesized cause: institutional fund flows and payroll contributions (401k contributions are typically invested on paydays, which cluster in the last week of months for many employers).
The Sell in May Effect
The old trading adage "Sell in May and go away" has some backing in data. Since 1950, the Dow has averaged a 0.6% gain from May through October and a 7.3% gain from November through April. The effect is more pronounced in some decades than others. But taxes and transaction costs for switching in and out often eliminate the benefit.
The Practical Answer
If you invest $500/month via a 401k or brokerage, just invest on the 1st of the month. The benefit of timing is small relative to the benefit of consistent investing. For foundational investing principles backed by decades of data, a classic investing fundamentals book covers why the timing question matters less than most people think. The person who invests $500/month for 30 years regardless of market conditions beats the person who tries to time entry points and misses 10 of those months.