Python time series forecasting libraries

Updated Nov 2026

Python time series forecasting libraries fit models to past observations and predict future values with uncertainty intervals. A statistical forecaster fits models such as ARIMA or exponential smoothing to each input series. These libraries let planning teams and AI agents forecast demand, traffic, and revenue.

Popularity

statsmodels has the most monthly downloads in this comparison, at 40.9M, a count that covers all its statistical modeling.

LibraryMonthly downloadsStarsLast releaseLicense
statsmodels
40.9M
11.8KAug 2026BSD-3-Clause
Prophet
4.1M
20.5KOct 2026MIT
StatsForecast
1.9M
5.0KJul 2026Apache-2.0
pmdarima
1.7M
1.7KNov 2025MIT
ARCH
1.1M
1.7KNov 2026NCSA
Chronos
969.3K
6.3KSep 2026Apache-2.0
TensorFlow Probability
894.9K
4.4KNov 2024Apache-2.0
sktime
678.5K
10.1KNov 2026BSD-3-Clause
Downloads: PyPI, last thirty days. Stars and releases: GitHub. Amber: no release in over a year.

Libraries and code examples

Runs statistical computations and models.

Downloads / mo
40.9M
Stars
11.8K
Last release
0.15.0
License
BSD-3-Clause
$ pip install statsmodels
from statsmodels.tsa.arima.model import ARIMA

model = ARIMA([10, 12, 11, 13, 12, 14, 13, 15], order=(1, 0, 0))
fitted = model.fit()
forecast = fitted.forecast(steps=2)

statsmodels examples

From open-source projects on GitHub

Fits time-series forecasts with nonlinear trends, seasonality, and holiday effects.

Downloads / mo
4.1M
Stars
20.5K
Last release
1.5.0
License
MIT

Strengths

  • Models recurring holiday effects. Pass event dates through holidays to include them in the forecast.
  • Backtests at historical cutoffs. Use cross_validation to compare earlier forecasts with observed outcomes.

Limitations

  • Regressors need future values. Supply predictor values for history and the complete forecast horizon.
  • Intervals assume recurring trend changes. Validate interval coverage against held-out history before relying on it.

Quickstart

From quick_start.md
$ pip install prophet
import pandas as pd
from prophet import Prophet

df = pd.DataFrame({
    'ds': pd.date_range('2025-01-01', periods=30, freq='D'),
    'y': list(range(30)),
})
model = Prophet()
model.fit(df)
future = model.make_future_dataframe(periods=2)
forecast = model.predict(future)

Prophet examples

From open-source projects on GitHub

Provides statistical forecasting models including ARIMA, ETS, CES, and Theta.

Downloads / mo
1.9M
Stars
5.0K
Last release
2.1.1
License
Apache-2.0

Strengths

  • Fits models across many series. Supply series identifiers, timestamps, and targets in a shared input frame.
  • Forecasts without retaining fitted models. Use forecast for predictions that do not need reusable fitted state.

Limitations

  • External predictors need future values. Forecast those predictors separately or remove them from the model.

Quickstart

From README.md
$ pip install statsforecast
from statsforecast import StatsForecast
from statsforecast.models import AutoARIMA
from statsforecast.utils import AirPassengersDF

df = AirPassengersDF
sf = StatsForecast(
    models=[AutoARIMA(season_length=12)],
    freq='ME',
)
sf.fit(df)
sf.predict(h=12, level=[95])

StatsForecast examples

From open-source projects on GitHub

Selects ARIMA models automatically, like the forecast package's auto.arima.

Downloads / mo
1.7M
Stars
1.7K
Last release
2.1.1
License
MIT

Quickstart

From README.md
$ pip install pmdarima
import pmdarima as pm

y = pm.datasets.load_wineind()
model = pm.auto_arima(y, seasonal=True, m=12)
forecast = model.predict(n_periods=2)

pmdarima examples

From open-source projects on GitHub

Implements ARCH models in Python.

Downloads / mo
1.1M
Stars
1.7K
Last release
9.0.0
License
NCSA

Quickstart

From introduction.html
$ pip install arch
from arch import arch_model

returns = [0.4, -0.2, 0.7, -0.5, 0.1, 0.8, -0.3, 0.2, -0.6, 0.5]
model = arch_model(returns, vol='GARCH', p=1, q=1)
fitted = model.fit(disp='off')
forecast = fitted.forecast(horizon=1)

ARCH examples

From open-source projects on GitHub

Provides pretrained models for time series forecasting.

Downloads / mo
969.3K
Stars
6.3K
Last release
2.3.2
License
Apache-2.0

Quickstart

From README.md
$ pip install chronos-forecasting
import pandas as pd
from chronos import Chronos2Pipeline

context = pd.DataFrame({
    'item_id': ['series'] * 64,
    'timestamp': pd.date_range('2025-01-01', periods=64, freq='D'),
    'target': list(range(64)),
})
pipeline = Chronos2Pipeline.from_pretrained('amazon/chronos-2', device_map='cpu')
forecast = pipeline.predict_df(context, prediction_length=2)

Chronos examples

From open-source projects on GitHub

TensorFlow Probability

Runs probabilistic modeling and statistical inference in TensorFlow.

Downloads / mo
894.9K
Stars
4.4K
Last release
0.25.0
License
Apache-2.0

Quickstart

From README.md
$ pip install tensorflow-probability
import tensorflow as tf
import tensorflow_probability as tfp

y = tf.constant([1., 2., 1.5, 2.5, 2., 3., 2.5, 3.5])
model = tfp.sts.LocalLevel(observed_time_series=y)
samples, _ = tfp.sts.fit_with_hmc(model, y)
forecast = tfp.sts.forecast(
    model, observed_time_series=y, parameter_samples=samples, num_steps_forecast=2
)

TensorFlow Probability examples

From open-source projects on GitHub

Provides a unified framework for machine learning with time series.

Downloads / mo
678.5K
Stars
10.1K
Last release
1.3.0
License
BSD-3-Clause

Quickstart

From README.md
$ pip install sktime
from sktime.datasets import load_airline
from sktime.forecasting.naive import NaiveForecaster

y = load_airline()
forecaster = NaiveForecaster(strategy='last')
forecaster.fit(y)
forecast = forecaster.predict(fh=[1, 2, 3])
print(forecast)

FAQ

Prophet suits forecasts with nonlinear trends, seasonality, and holiday effects. StatsForecast suits ARIMA, ETS, and Theta models fitted across many series. Chronos suits pretrained forecasting models. statsmodels suits classical statistical models.

StatsForecast provides statistical forecasting models including ARIMA, ETS, CES, and Theta. It fits each specified model to each input series.

Prophet fits time series forecasts with nonlinear trends, seasonality, and holiday effects. It expects a dataframe with ds timestamps and numerical y observations.

sktime is a unified framework for machine learning with time series.

pmdarima selects ARIMA models automatically, as the Python equivalent of the forecast package's auto.arima.

For coding agents

Found your time series forecasting library? Help your agent use it.

Connect Exa so your coding agent can find the library’s documentation, check its API, and look up implementations while you build.

Run in your terminal

claude plugin install exa@claude-plugins-official