A new unsupervised domain adaptation algorithm based on class centroid alignment (CCA) is proposed for classification of remote sensing images. The approach aims to align the class centroids of two domains by moving the target domain samples toward source domain, with the moving direction equaling to the difference of the associated class centroids between two domains. After moving, the data distributions become similar and the classifier trained in source domain can be used to predict the changed target domain data. Since there lacks labeled information in target domain, the class centroids and moving directions are estimated based on the predicted results. Moreover, better moving directions can be determined by preserving the local similarity in the changed target domain, resulted in neighborhood based CCA (NCCA) method. Experiments with Hyperion, AVIRIS, and NCALM hyperspectral images and Worldview-2 multispectral images demonstrated the effectiveness of applying CCA and NCCA in reality.