Analytical and numerical study of the stability of the resistive ballooning modes (RBM) in the scrape-off layer (SOL) of a tokamak plasma is performed. It is shown that the stability of the RBM is controlled by the two parameters lambda = (m(e)/m(i))(1/2)nu(ei)qR/upsilon(Te)-the ''effective strength'' of the Debye sheath current, and (m) over cap = mL(0)/a the dimensionless poloidal number, where the characteristic scale L(0) is given in the main text as a function of the basic plasma edge parameters. For lambda>1 the coupling to the sheath is unimportant and the unstable spectrum is virtually unchanged from that in the closed flux region. For lambda<1 the sheath current has a strong destabilizing influence on long wavelength modes. The general case of arbitrary lambda and (m) over cap is studied numerically and the spectrum of the unstable RBM is found. The influence of the diamagnetic effects is also investigated. (C) 1995 American Institute of Physics.