This study proposes a data-based algorithm to select a subset of indicators from a large data set with a focus on forecasting recessions. The algorithm selects leading indicators of recessions based on the forecast encompassing principle and combines the forecasts. An application to U.S. data shows that forecasts obtained from the algorithm are consistently among the best in a large comparative forecasting exercise at various forecasting horizons. In addition, the selected indicators are reasonable and consistent with the standard leading indicators followed by many observers of business cycles. The suggested algorithm has several advantages, including wide applicability and objective variable selection.