The narrowband interference (NBI) can degrade the synthetic aperture radar (SAR) imaging quality severely. This paper proposes an NBI mitigation method using the variational mode decomposition (VMD). The coarse estimation of NBI is obtained by decomposing the real part and imaginary part of the complex-valued raw echoes into a number of modes by VMD independently. Next, modes that correspond to NBI are refined by the mask technique in the frequency domain. Then the interference is mitigated by subtracting the refined estimated NBI components from the echoes, and a well-focused SAR image is obtained by conventional imaging schemes. The proposed method outperforms other time-varying NBI mitigation methods with smaller effective data loss and less impact on the focusing performance of images. Results of simulated and measured data prove the validity of the proposed method.