We propose a new invariant sign test for random walks against general stationary processes and develop a theory for the test. In addition to the exact binomial null distribution of the test, we establish various important properties of the test: the consistency against a wide class of possibly nonlinear stationary autoregressive conditionally heteroscedastic processes and/or heavy-tailed errors; a local asymptotic power advantage over the classical Dickey-Fuller test; and invariance to monotone data transformations, to conditional heteroscedasticity and to heavy-tailed errors, Using the sign test, we also investigate various interrelated issues such as M-estimator, exact confidence interval, sign test for serial correlation, robust inference for a cointegration model, and discuss possible extensions to models with autocorrelated errors. Monte-Carlo experiments verify that the sign test has not only very stable sizes but also locally better powers than the parametric Dickey-Fuller test and the nonparametric tests of Granger and Hallman (1991. Journal of Time Series Analysis 12, 207-224) and Burridge and Guerre (1996. Econometric Theory 12, 705-719) for heteroscedastic and/or heavy tailed errors. (C) 2001 Elsevier Science S.A. All rights reserved.