This work is devoted to an adaptive multiscale finite element method (MsFEM) for solving elliptic problems with rapidly oscillating coefficients. Starting from a general version of the MsFEM with oversampling, we derive an a posteriori estimate for the H-1-error between the exact solution of the problem and a corresponding MsFEM approximation. Our estimate holds without any assumptions on scale separation or on the type of the heterogeneity. The estimator splits into different contributions which account for the coarse grid error, the fine grid error, and the oversampling error. Based on the error estimate, we construct an adaptive algorithm that is validated in numerical experiments.