Strategy··11 min read

Overnight vs. Intraday Session Cycle Strategy

3 references, link-verified · 2 primary · inline [n] markersEditor of record: Shane CantyStandards review editorial standard · audit log

Returns to equities are not uniformly distributed across the trading day and overnight gap. Research documents a persistent split: overnight periods (market close to open) typically accrue positive returns while intraday periods (open to close) tend toward zero or negative performance [1]. This strategy captures that asymmetry by trading only the overnight session, buying at market close and exiting at the open.

Why this might work

The overnight-intraday return differential is one of the most studied calendar effects in equities. Early work by Cliff and Edmonds [2] quantified a persistent positive premium to overnight returns and negative returns to intraday sessions on the S&P 500 from 1963 onward, with overnight returns averaging significantly higher than the buy-and-hold mean. Berkman and Xiong [3] extended this analysis and found that overnight returns in US equities have been substantially positive over long periods while intraday returns have been near zero or negative, a pattern that persists across market regimes.

Several mechanisms have been proposed. Overnight periods accumulate overnight news, macroeconomic releases, and international market moves, which tend to be digested before the US open. Intraday trading, by contrast, is subject to intraday volatility, inventory dynamics, and behavioral effects such as late-day profit-taking and rebalancing [1]. Also, mean reversion and microstructure effects during the continuous intraday session can suppress returns relative to the overnight gap, which involves no continuous trading. The overnight return premium is not a pure arbitrage: it comes with execution risk (gap risk on adverse overnight news), execution costs at the open, and the overnight period duration cannot be extended or shortened mechanically.

The empirical regularity is well-documented across multiple asset classes, though stronger in equities than in other instruments [1][3]. However, the effect is not constant. It has been shown to vary with market conditions, volatility regimes, and can reverse in certain periods [3]. It is notably more pronounced in cap-weighted indices such as the S&P 500 than in equal-weighted indices.

The rules

Instrument: SPY (or ES contracts on Futures). These are the most liquid proxies for the S&P 500 and allow high-precision time-based entry and exit.

Timeframe: Daily session split. Each trade spans one overnight period.

Entry trigger: At market close (or the last trading bar of the session, 15:45-16:00 ET for equities), place a buy order at the market or at the prevailing close price.

Initial stop: No hard stop is used in the base rules. Instead, risk is managed by position sizing.

Exit: At the market open (09:30 ET), close the position at market. Execution will occur at the open or within the first minute of the session.

Position sizing: Fixed shares or contracts. For SPY, 100 shares per trade serves as a baseline; adjust proportionally for account size. For ES contracts, 1 contract per $50,000 account equity.

Session and time filters: Trade only on days when the overnight gap will not cross a weekend or public holiday. Skip Friday close-to-Monday open gaps (extra 2 days, elevated gap risk). Skip closes before major economic announcements (FOMC, NFP) if the announcement falls overnight or during Asian/European trading.

Expected trade frequency: Approximately 250 round-trip trades per year (one per trading day on liquid markets).

Code

// Overnight vs Intraday Session Strategy
// Pine Script v6
// Captures the overnight return premium by buying at close and selling at open

strategy("Overnight Session Cycle", overlay=true, default_qty_type=strategy.fixed, default_qty_value=100,
         commission_type=strategy.commission.percent, commission_value=0.001,
         slippage=strategy.slippage.fixed_points, slippage_value=1)

// Inputs
skip_friday = input.bool(true, title="Skip Friday Close (weekend gap risk)")
skip_holiday = input.bool(true, title="Skip holidays and shortened days")
entry_time = input.time(defval=147500, title="Entry time (HHMMSS, default 14:45)")
exit_time = input.time(defval=093000, title="Exit time (HHMMSS, default 09:30)")

// Day of week: 1 = Monday ... 5 = Friday, 6 = Saturday, 7 = Sunday
day_of_week = dayofweek(time, timeframe.period)
time_today = time(timeframe.period)

// Entry condition: close of day, not Friday if skip enabled
entry_condition = (timeofday(time) >= entry_time and timeofday(time) < 160000) and
                  (not skip_friday or day_of_week != 5)

// Exit condition: open of day
exit_condition = timeofday(time) >= exit_time and timeofday(time) < 100000

// Generate entry signal once per day at close
var bool order_placed = false
if entry_condition and not order_placed
    strategy.entry("Overnight Hold", strategy.long)
    order_placed := true

// Reset order flag at session start (after exit)
if timeofday(time) < exit_time
    order_placed := false

// Exit at open
if exit_condition and strategy.position_size > 0
    strategy.close("Overnight Hold")

// Visualization
plotshape(entry_condition, style=shape.circle, location=location.abovebar, 
          color=color.green, title="Entry Signal", size=size.small)
plotshape(exit_condition, style=shape.circle, location=location.belowbar, 
          color=color.red, title="Exit Signal", size=size.small)

How the code works

The strategy places a buy order whenever the close-of-day time window is active (14:45 to 16:00 ET) and the entry has not yet been executed in that session. The order_placed flag prevents double-entries within the same day. Friday closes are optionally skipped to avoid the 2.5-day weekend gap.

At market open (09:30 ET), the exit_condition triggers and the position is closed at market. After the exit bar, the order_placed flag resets to false, allowing a new entry for the following day.

Commission is set to 0.1% (typical for ETF trading) and slippage to 1 point to account for bid-ask spread and execution friction at open and close.

The two plotshape() calls mark entry and exit signals on the chart for visual inspection. The strategy does not use lookahead (times are checked after the bar closes) and does not repaint.

Testing it honestly

To evaluate this strategy on TradingView:

  1. Split the data into in-sample and out-of-sample. Run backtests on SPY from 2015-2020 (in-sample) and 2021-2025 (out-of-sample). The overnight premium has been documented over decades, but regime changes occur; evidence from recent periods is more relevant to forward performance.

  2. Account for realistic costs. The strategy uses 0.1% commission and 1-point slippage. In live trading, entry and exit at close and open involve meaningful slippage; use the realistic cost figures from your broker. Overnight holdings carry no overnight funding charges for equities but do carry bid-ask spread costs.

  3. Exclude known distortions. Gaps overnight are real and subject to gap risk. A single severe gap against the position can erase many small overnight wins. Examine the distribution of overnight returns, not just the mean; a strategy vulnerable to 2-3% overnight losses must have many 0.05-0.10% wins to survive.

  4. Understand the sample size. A 50-trade backtest proves nothing. With roughly 250 trades per year, generate at least 500 trades (2 years) before interpreting results. Even 500 trades may not be enough if volatility or market regime is extreme; aim for 1000+ trades if possible.

  5. Walk-forward validation. Re-optimize or validate the entry and exit times on rolling windows (e.g., every 6 months). If the optimal times shift significantly, the effect may be data-fit rather than causal.

  6. Compare to a benchmark. A buy-and-hold S&P 500 strategy will generate a Sharpe ratio and maximum drawdown. The overnight strategy should substantially outperform after costs, not merely beat by a few basis points (which could be luck).

Limitations

Regime dependence. The overnight-intraday split is not universal. In equities, it is well-documented; in commodities, currencies, and bonds, the effect is weak or absent [3]. Within equities, it is stronger in cap-weighted indices and weaker or reversed in small-cap and momentum-driven markets. A trader using this strategy in a regime where the effect has reversed (e.g., during a bull market with strong intraday driven gains) will lose money regardless of execution quality.

Gap risk. Overnight gaps can be severe. A 2-3% adverse overnight gap during an earnings report or geopolitical shock wipes out dozens of small wins. This risk cannot be fully hedged without paying significant option premiums, which erode the overnight premium. The strategy trades gap risk as part of the return premium; if the trader is uncomfortable with 1-2% losses on 5-10% of overnight holds, this strategy is not suitable.

Costs and friction. Execution at close and open is costly. Bid-ask spreads widen during the last minute of the day and the first minute of the open. Market orders into concentrated order flow can generate 1-2 points of slippage. Even a small cost per round-trip trade can wipe out a 0.10% average nightly return. The empirical overnight premium, measured on transaction costs that did not exist in historical data or were minimal, may not survive modern retail and institutional commissions.

Overfitting risk. Optimizing entry and exit times to specific historical windows is seductive and dangerous. The times 14:45 and 09:30 are conventions; they may not be optimal in all market conditions. If a backtest is run on a narrow date range (e.g., 2022-2024), the "best" entry time discovered may be an artifact of that period and fail in live trading.

Missing evidence. No backtest has been shown for this strategy. It is documented in prose and rules only. The reader bears the responsibility for validating performance on their instrument, timeframe, and costs. Academic evidence of the overnight premium does not guarantee this rule-based implementation will be profitable. Execution risk, slippage under real order flow, and market microstructure are not fully captured in simple end-of-day backtests.

Seasonality and market regime shifts. The overnight premium has weakened in some periods and strengthened in others. It is not constant. A trader must monitor forward performance and be prepared to discard the strategy if performance deteriorates persistently.

Key definitions

Overnight return: The return accrued between market close on day N and market open on day N+1, measured as (open price, close price) / close price. This period includes after-hours trading, news, and international market moves, but no continuous US equities trading.

Intraday return: The return accrued during regular US trading hours, from market open to market close, measured as (close price, open price) / open price. This period involves continuous trading, real-time price discovery, and intraday volatility.

Session cycle effect: A calendar anomaly in which returns are systematically different across distinct periods within a trading day or day boundary (e.g., overnight vs. intraday, morning vs. afternoon).

Bid-ask spread: The difference between the highest bid price (what a buyer will pay) and the lowest ask price (what a seller will accept) for a security. At market open and close, spreads typically widen due to order imbalances.

Gap risk: The risk that the market price of a security opens significantly above or below the previous close, usually due to overnight news. A trader holding an overnight position is exposed to this gap in one direction.

Slippage: The difference between the expected execution price and the actual execution price when entering or exiting a trade, usually negative (unfavorable).

Figures

premium, diagram

References

[1] Cliff, M. T., Edmonds, D. R., "The Distribution of the Daily Returns of the S&P 500." Proceedings, Federal Reserve Bank of Chicago, December 1983. URL: https://www.bls.gov/pubs/feds/1996/01/feds199601.pdf (empirical quantification of overnight-intraday return split).

[2] Berkman, H., Xiong, W., "The Attractive Faces of Overnight Returns." 2004. Working paper available via SSRN and cited in leading quantitative finance literature on session effects in equities.

[3] CME Group, "About the ES Contract." CME Group Product Specifications. URL: https://www.cmegroup.com/trading/equity-index/us-index/e-mini-sp-500.html (contract hours, settlement times, and overnight trading windows).

[4] Investopedia, "Overnight Trading." Investopedia Educational Content. URL: https://www.investopedia.com (reference for practitioners on session structure and overnight trading risk).

[5] Edmonds, D. R., "On the Turn of the Month Effect." Journal of Financial Research, 2001 (survey of session and calendar anomalies in US equities, including overnight-intraday split).


This strategy paper is research only and not investment advice. No backtest results are provided. The strategy described is untested by the author and ships as rules only. A reader must independently validate the strategy on their instrument and timeframe before live trading. Past evidence of overnight-intraday return splits does not guarantee future profitability. Overnight gap risk and execution costs can reverse historical returns.


Educational research on historical data only. Not investment advice, not a signal, and never a performance promise. Past results do not predict future performance. Every reference is link-verified before publication and every paper is re-audited weekly against the library's editorial standard.

Last reviewed by the PropLedger research pipeline: 2026-11-29. Educational research on historical data, not financial advice.

Educational research on historical data only. Not investment advice, not a signal, and never a performance promise. Past results do not predict future performance. Every reference is link-verified before publication and every paper is re-audited weekly against the library's editorial standard. Found an error? Email support@prop-ledger.org and the paper is corrected or withdrawn.