Math calculator

Augmented Dickey-Fuller Calculator

Does it wander.

Testing for a root

A hundred and twenty steps of a random walk — the behaviour a price series is usually assumed to have. The statistic is −1.3475 against a 5% critical value of −2.8859, so the unit root is not rejected, and the estimated root is 0.9644. KPSS on the same series gives 1.5371 against 0.463 and rejects stationarity. Both tests agree, which is the comfortable case: this series has to be differenced before anything that assumes stationarity is applied to it.

120 observations · 118 used · 1 lag · constant term

Statistic -1.3475 against a 5% critical value of -2.8859 — the unit root stands

The estimated root is 0.9644, from a coefficient of -0.0356 on the lagged level with a standard error of 0.0264. KPSS on the same series gives 1.5371 against 0.463 and rejects stationarity.

Statistic

-1.3475

5% cutoff -2.8859

Estimated root

0.9644

mean-reverting

A t table would say

do not reject

cutoff -1.9600 — wrong here

Verdict stable across lags

yes

orders 0 to 1

Critical values, and the one people use by mistake

Dickey-Fuller critical values at three levels against the ordinary t cutoff
LevelCritical valueRejectedHow far past a t cutoff
1%-3.4865no0.911 further
5%-2.8859no0.926 further
10%-2.5796no0.935 further
Student t at 5%-1.9600nothe wrong distribution

These come from MacKinnon’s response surface, which corrects for the sample size — the finite-sample value at 118 usable observations is stricter than the asymptotic one. The last row is what a regression package would print if you read the t statistic off the output and stopped there.

The statistic at every lag order

The Dickey-Fuller statistic and verdict at each lag order, with the information criterion
LagsStatisticVerdict at 5%AIC
0-1.2384unit root stands110.26
1-1.3475unit root stands109.17

Lags are included to soak up serial correlation in the differences, and too few leaves the test oversized while too many cost power. The AIC column is the usual tiebreaker and it is a preference rather than a proof.

Combined with KPSS, whose null is the opposite: Both tests agree the other way: the unit root stands and stationarity is rejected.This test alone cannot distinguish “there is a unit root” from “there is not enough data to tell”, and running both is the only way to separate them.

A one-time level shift makes this test fail to reject on a series that is plainly stationary within each segment. That is a known result rather than a quirk, and it means a structural break has to be ruled out before a non-rejection is read as a unit root.

Correct critical values Lag order swept KPSS alongside Blind to breaks

What this tool shows

On the third preset the statistic is −2.6839, the correct 5% critical value is −2.8909, and the unit root stands. An ordinary t cutoff of −1.9600 would have rejected it comfortably. That is not a rounding difference, it is the opposite conclusion. Under the null the lagged level is itself non-stationary, so the statistic does not follow Student’s t — and reading it off a regression printout as though it did is the single most common error with this test.

  • The ADF statistic with MacKinnon critical values at 1, 5 and 10 per cent, corrected for sample size
  • The ordinary t cutoff printed beside them, so the size of the difference is visible
  • The statistic and verdict at every lag order from zero upward, with the AIC
  • Three deterministic specifications — none, constant, and constant with trend
  • The estimated autoregressive root, which says how persistent the series is
  • KPSS on the same series, because the two tests have opposite nulls and all four combinations occur
Correct critical values Lag order swept KPSS alongside Blind to breaks

A structural break makes this test fail to reject.

Updated 13 September 2026 · Works in any browser, no installation

The augmented Dickey-Fuller test asks whether a series has a unit root — whether shocks to it persist forever rather than dying out. It regresses the change on the previous level plus enough lagged changes to clean up the residuals, and tests whether the coefficient on that level is zero. The statistic looks like a t ratio and is not one: its null distribution is far into the left tail, because under the null the regressor is non-stationary.

At a glance

Formula shown
Δyₜ = α + δt + γyₜ₋₁ + Σφᵢ Δyₜ₋ᵢ + εₜ, and the test is whether γ = 0. The statistic is γ̂ divided by its standard error, referred to the Dickey-Fuller distribution rather than Student’s t — the 5% cutoff is about −2.86 with a constant and −3.41 with a trend, against −1.96 for a t test. The implied autoregressive root is 1 + γ̂, so γ̂ = 0 means a root of exactly 1.
Scenario support
Deciding whether a series needs differencing before an ARIMA or regression model, checking whether two series can be tested for cointegration, distinguishing a trend that will continue from one that will revert, and screening any time series before applying a method that assumes stationarity.
Educational estimate
Planning support from the values you enter — not professional advice.

It looks like a t statistic and is not one

This is the error the third preset is built to demonstrate, and its size is easy to state.

The statistic is −2.6839. Against a t cutoff of −1.9600 that is comfortably significant; against the correct −2.8909 it is not.

The correct cutoff is roughly 46% further into the left tail, and the gap is larger still with a trend term, where the 5% value is about −3.41.

The reason is that the null makes the regressor non-stationary. The usual asymptotics for a t ratio assume the regressor has a finite variance, and a unit-root process does not.

The page prints both cutoffs for that reason. A regression package will happily report a t statistic and a p-value on the lagged level, and both are wrong here.

The lag order changes the verdict

The number of lagged differences is a modelling choice, and on the fourth preset it decides the answer outright.

At zero lags the statistic is −3.048 and the unit root is rejected.

At one lag it is −2.027, at two −2.164, at six −1.857. None of them close to the cutoff.

Too few lags leaves serial correlation in the residuals and oversizes the test; too many cost degrees of freedom and power. Neither error announces itself.

So the sweep is the output. A rejection that appears at one lag order and disappears at the next is a property of the specification rather than of the series, and the information criterion that picks between them is a preference rather than a proof.

A single break defeats it

The best-known limitation of this test is that a one-time level shift makes it fail to reject on a series that is obviously stationary within each segment.

The same noise and the same autoregressive coefficient, with one level shift added, moves the statistic from −4.7202 to −0.9540. Decisively stationary to no evidence at all.

Nothing about the series changed except one step in its mean. The shift is read as persistence, because persistence is what the test is looking for.

This is Perron’s result, and it rewrote a literature. Series that had been declared unit roots turned out to be stationary around a broken trend.

The practical rule is to plot the series first. If there is a visible break, the standard test is not the right one and a break-aware variant is needed — the KPSS test does not rescue you either, since it rejects stationarity on the same data.

Which deterministic terms to include

The three specifications answer different questions and have different critical values, and picking the wrong one costs power or size.

No constant assumes the series has mean zero. Rarely right for a level series and often right for a differenced one.

A constant is the usual default. It tests a unit root against stationarity around a fixed mean.

A constant plus trend tests against stationarity around a straight line. Use it when the series plainly trends, and note the critical value moves from about −2.86 to −3.41, so the same statistic can reject under one and not the other.

Including a trend that is not there costs power; omitting one that is there makes the test fail to reject almost always. Looking at the series before choosing is not optional.

Pair it with a test of the opposite null

A non-rejection here means the data did not provide evidence against a unit root, which is not the same as evidence for one.

ADF has a unit root as its null; KPSS has stationarity. Running both gives four possible combinations rather than two.

Both agreeing is the comfortable case, and the first two presets show it in each direction.

Neither rejecting means the data is uninformative — usually a short series or a noisy one. That is an honest answer, and a single test cannot produce it.

Both rejecting points at something neither models: a structural break, fractional integration, or a mis-specified deterministic term.

It has little power near a unit root

The test is known to be weak against alternatives close to 1, which matters because that is exactly where most economic and financial series sit.

A root of 0.95 and a root of 1.00 look nearly identical over a hundred observations. The first preset has an estimated root of 0.9644 and does not reject.

Distinguishing them needs a long series, and span matters more than frequency — twenty years of annual data beats one year of daily data for this purpose.

So a non-rejection at n = 100 is weak evidence. The estimated root printed on the page is more informative than the verdict: 0.96 and 0.55 are very different series and both may fail to reject.

Which is why the root is shown beside the statistic, and why the honest summary is usually a magnitude rather than a yes or no.

Reporting a unit root test

Four items, and the first two are what make the result reproducible at all.

Give the deterministic specification. The critical value moves from about −2.86 to −3.41 between the constant and trend cases.

Give the lag order and how it was chosen. The verdict can change between adjacent orders, as the fourth preset shows.

Give the estimated root, not just the verdict. 0.96 and 0.55 both fail to reject at short samples and are not the same finding.

And say whether you looked for a break. A non-rejection with an unexamined level shift in the series is not evidence of a unit root.

Sources and methodology

References for the test and its critical values.

Method. Critical values come from MacKinnon’s 1996 response surface rather than from a fixed table, so they correct for the usable sample size at every specification instead of using the asymptotic value at every n. The verification suite checks them against the published large-sample figures — −3.43, −2.86 and −2.57 for the constant case and −3.96, −3.41 and −3.13 with a trend — and asserts that the finite-sample value is always stricter. Behaviour is checked at both extremes rather than on transcribed examples: across 150 generated series the test must reject the unit root on white noise every time, and must hold close to its nominal 5% size on a random walk. The lag sweep recomputes the regression at every order from zero upward, which is what makes an unstable verdict visible. That engine is verified on every change against 115 assertions. The count and the per-case breakdown are published on the formula verification page.

Related calculators

Where this goes next:

KPSS TestStationarity as the null hypothesis, with Dickey-Fuller alongside and all four combinations of the two verdicts named — including the one that means the data cannot tell.
ARIMAARIMA(p, d, q) with coefficients and standard errors, residual Ljung-Box, a Dickey-Fuller result on the raw series, and over-differencing detected and named.
AutocorrelationACF and PACF at every lag with Bartlett bands that widen rather than a flat line, plus the shapes that identify a model.
Durbin-WatsonThe Durbin-Watson statistic with dL and dU computed by Imhof inversion rather than tabled, so the bounds exist at any n and k.
Seasonal DecompositionTrend, seasonal indices and remainder, additive or multiplicative, with the index sum printed against the value it must take and both models compared on the same data.
Ljung-Box TestThe Ljung-Box portmanteau test with Box-Pierce beside it, the degrees-of-freedom correction for fitted models and a lag-by-lag table.

More in Math, or browse all calculators.

Educational use disclaimer

An educational tool. The Dickey-Fuller statistic does not follow Student’s t, and the critical values here come from MacKinnon’s response surface rather than a normal or t table. The test has low power against roots close to 1 and fails to reject on a stationary series containing a structural break — a non-rejection is an absence of evidence rather than evidence of a unit root.

How we calculate · Found an error? email us

Authorship & verification

Written and maintained by , a business operator who builds spreadsheet-based calculators.

What's changed (5 updates)

Published 13 September 2026

  1. Published the unit root test with MacKinnon critical values corrected for sample size.
  2. Printed the ordinary t cutoff beside them, since using it reverses the verdict.
  3. Computed the statistic at every lag order from zero, and flagged when the verdict changes.
  4. Shipped three deterministic specifications with their different critical values.
  5. Added KPSS on the same series, because the two nulls are opposite.

Add this calculator to your site

Responsive embed — and private: nothing your visitors type leaves their browser.