Predicting whether asset prices will rise or fall is essential for investment decision-making, since even modest improvements in directional accuracy can produce substantial economic benefits. This study proposes a dynamic sliding-window (DSW) framework for the daily directional classification of Exchange-Traded Funds (ETFs). Unlike conventional forecasting approaches that rely on either a fixed training sample or an expanding window, the DSW method allows the length of the estimation window to change at every prediction step. The underlying premise is that observations associated with market conditions that are most relevant to the current regime may provide more useful predictive information than a larger volume of older data. For each forecast, the optimal dynamic sliding-window size is selected through Bayesian optimisation applied to an internal validation segment of the available training sample, with a Gaussian process used as the surrogate model. A linear Support Vector Machine is then estimated using the observations contained in the selected window and a set of 39 technical indicators representing different dimensions of market behaviour. The empirical evaluation is conducted on 156 US-listed ETFs obtained from Yahoo Finance over the period from September 2019 to September 2024, yielding more than 170,000 daily observations. The dynamic sliding-window model achieves statistically significant improvements across all evaluation measures when compared with both an expanding, or stretching, window and a conventional train–test split. These results show that dynamically adapting the amount of historical data used for model estimation can improve financial time-series classification. The proposed DSW framework therefore provides a scalable and transparent approach to forecasting in markets characterised by changing regimes and persistent volatility.