The images captured in the underwater scene frequently suffer from blur effects due to the insufficient light and the relative motion between the captured scenes and the imaging system, which severely hinders the visual-based exploration and investigation in the ocean. In this paper, we propose a feature pyramid attention network (FPAN) to remove the motion blur and restore the blurry underwater images. FPAN incorporates the cascaded attention modules into the feature pyramid network (FPN) that enables it to learn more discriminative information. To facilitate the training of FPAN, we construct a weighted loss function, which consists of a content loss, an adversarial loss, and a perceptual loss. The cascaded attention module and the weighted loss function enable our proposed FPAN to generate more realistic high-quality images from the blurry underwater images. In addition, to deal with the lack of publicly available datasets in underwater image deblurring, we built two specific underwater deblurring datasets, namely Underwater Convolutional Deblurring Dataset (UCDD) and Underwater Multi-frame Averaging Deblurring Dataset (UMADD), to train and examine different deep learning-based networks. Finally, we conduct sea trial experiments on our autonomous underwater vehicle (AUV). Experimental results on two underwater deblurring datasets demonstrate our proposed method achieves satisfactory results, which validates the potential practical values of our proposed method in real-world applications.