In this paper, we propose a lossless compression algorithm for hyperspectral images; it is based on the adaptive classified arithmetic coding in wavelet domain and the adaptive spectral band reordering algorithm. The adaptive classified scheme divides each of the residual images after wavelet transform into different classes, and then the adaptive arithmetic coding is performed for each of the classes. This classified coding scheme saves a lot of coding bits. The adaptive spectral band reordering algorithm finds out the nearly best reference band for each of the bands, so the spectral correlation is better used. Combining these two algorithms makes full use of the characteristics of hyperspectral images. Experiments show that our method is capable of providing a high compression performance.