Recursive forecasting

Also known as: iterative multi-step forecasting

On this page 7

Recursive forecasting is a multi-step strategy in which a single one-step-ahead model predicts the next value of a time series, appends that prediction to the history, and repeats the process until the full forecast horizon is covered. It is also known as iterative multi-step forecasting, and it is one of the two classic strategies for multi-step prediction in time series & forecasting, alongside the direct strategy.

In artificial intelligence and statistics, recursive forecasting is the default behavior of autoregressive models such as ARIMA and of many machine learning forecasters built on lag features. Its appeal is simplicity: one model serves any horizon. Its main weakness is that errors compound, because every later prediction depends on earlier predictions rather than on observed data.

How recursive forecasting generates multi-step predictions

Recursive forecasting builds a horizon of h steps from h successive one-step predictions. The model is trained to map a window of recent observations, plus optional calendar features or exogenous covariates, to the next value. At inference time the window slides forward, and each predicted value replaces a missing observation in the input.

For a model that uses the last three values, the first forecast uses three observed values. The second forecast uses two observed values and one predicted value, and from the fourth step onward the input consists entirely of predictions. Rolling window features and differenced inputs must be recomputed at each step from this mixed history, which is a frequent source of implementation bugs.

The table below traces the inputs for a model with three lag features forecasting four steps ahead.

Forecast stepLag 1 inputLag 2 inputLag 3 input
Step 1Observed value tObserved value t-1Observed value t-2
Step 2Predicted t+1Observed value tObserved value t-1
Step 3Predicted t+2Predicted t+1Observed value t
Step 4Predicted t+3Predicted t+2Predicted t+1
Inputs used at each step of a recursive forecast

Exogenous covariates add a further requirement: their future values must be known or forecast for every step. Known-in-advance inputs, such as holidays or planned prices, are safe; unknown covariates must themselves be predicted, which adds a second source of error.

Error accumulation and exposure bias

The central weakness of recursive forecasting is error accumulation: a mistake at step one shifts the input for step two, and the deviation can grow with every iteration. For a stable linear autoregressive process the forecast error variance grows with the horizon and converges toward the variance of the series itself, which is mathematically expected and not a defect of implementation.

Nonlinear models trained with teacher forcing, meaning on true lagged values only, face an additional problem called exposure bias. During training they never see their own imperfect predictions as inputs, so at inference they operate on a different input distribution. Gradient-boosted trees and neural networks can drift, oscillate or collapse toward the mean over long horizons.

Model familyBehavior over long horizonsMain reason
Linear autoregressive modelSmooth reversion toward the meanStable coefficients dampen errors
Gradient-boosted treesFlat or step-like forecastsTrees cannot extrapolate beyond training range
Recurrent neural networkPossible drift or oscillationExposure bias in autoregressive decoding
Exponential smoothingStable trend and seasonal patternClosed-form state recursion
Typical error behavior by model family

Common mitigations include scheduled sampling, which gradually replaces true inputs with predictions during training, and training on multi-step loss computed over unrolled predictions. Both reduce exposure bias but increase training cost.

Recursive forecasting compared with other multi-step strategies

Recursive forecasting is one of several strategies for producing multi-step forecasts, and the right choice depends on horizon length, data volume and compute budget. The direct forecasting strategy trains a separate model for each horizon step, avoiding feedback of predictions at the cost of more models and less shared information.

StrategyModels trainedError accumulationKey trade-off
RecursiveOneYes, compounds over stepsSimple but biased at long horizons
DirectOne per horizon stepNo feedback errorsHigher variance, inconsistent steps
DirRec hybridOne per step, using earlier predictionsPartialMost expensive to train
Multiple-outputOne model emitting a vectorNo feedback errorsNeeds enough data per output
Sequence-to-sequenceOne encoder-decoderDepends on decoder typeFlexible but data-hungry
Main multi-step forecasting strategies

Empirical comparisons, including results from the M competitions, show no universally superior strategy. Recursive methods often win at short horizons and with limited data, while direct and multiple-output approaches tend to perform better when the horizon is long and the model is nonlinear.

When to choose recursive forecasting

Recursive forecasting is a sound default when the horizon is short relative to the seasonal cycle, when training data is limited, or when the same model must serve horizons of different lengths. It also keeps forecasts internally consistent, because each step is generated by the same dynamics.

SituationRecommended strategyReason
Short horizon, small datasetRecursiveOne model uses all data efficiently
Variable or open-ended horizonRecursiveAny length without retraining
Long horizon with nonlinear modelDirect or multiple-outputAvoids compounding errors
Unknown future covariatesDirectNo need to forecast inputs
Strong linear dynamicsRecursiveMatches the data-generating process
Decision guide for multi-step strategy selection

Whatever the choice, evaluate with time series cross-validation that reproduces the full recursive loop on each validation fold. Scoring only one-step-ahead accuracy, a common mistake, hides the compounding error that appears in production and makes the model look better than it is.

Common implementation mistakes

  • Data leakage in features: rolling statistics computed with observed future values instead of predictions.
  • One-step evaluation only: reported metrics such as MASE describe step one, not the full horizon.
  • Ignoring uncertainty growth: point forecasts are reported without widening prediction intervals.
  • Wrong inverse transforms: differenced or scaled predictions are not restored before being fed back.

For probabilistic forecasting, sampling full trajectories, as DeepAR does, propagates uncertainty correctly, whereas feeding back only the mean prediction produces intervals that are systematically too narrow.

Stripped to the essentials

Imagine guessing tomorrow’s temperature from the last three days. To guess the day after tomorrow, you have no real reading for tomorrow yet. So you use your own guess instead. Recursive forecasting repeats this step by step.

The method is simple and needs only one model. The catch is that small mistakes pile up. A guess built on earlier guesses is less certain than a guess built on real measurements. That is why forecasts far into the future are less reliable.

Where it is applied

A regional electricity operator forecasts hourly load for the next 48 hours. Its gradient-boosted model uses the previous 24 hourly loads, hour-of-day and weekday features, and a temperature forecast from the weather service as an exogenous covariate.

The team runs the model recursively: each predicted hour becomes the newest lag for the following hour. Backtesting over two years shows that error is low for the first six hours, then roughly doubles by hour 36, mostly on days with sudden weather changes.

The operator keeps the recursive model for the intraday horizon and adds direct models for hours 25 to 48. The combined setup reduces day-ahead error and gives dispatchers more reliable figures for scheduling reserve generation.