Currently, the larger-scaled commercialization of fuel cell technology is considerably impeded by the limited durability of fuel cells. Prognostics and health management (PHM) is one of the most widely researched technologies used to improve the durability of fuel cell devices. More recently, the combination of deep neural network approaches and PHM techniques shows a broad research prospect. Attention mechanisms can enhance their data processing ability, which helps to extract useful features more efficiently. Herein, we propose an attention-based Recurrent neural network (RNN) model to improve the prognostics of PHM, which enables a more accurate prediction of the output voltage degradation of proton exchange membrane fuel cell (PEMFC) based on the original long-term dynamic loading cycle durability test data. In particular, the prediction results with different prediction models, namely, long short-term memory (LSTM), gated recurrent unit (GRU), attention-based LSTM, and attention-based GRU are obtained and compared. For dynamic test data (dataset 1), the root mean square error results for the attention-based LSTM and GRU models are 0.016409 and 0.015518, respectively, whereas for the LSTM and GRU model the corresponding error results are 0.017637 and 0.018206, respectively. The same effects are demonstrated and proved for the pseudo–steady dataset (dataset 2). The attention-based RNN model achieves a high prediction accuracy, proving that it can help improve the prediction accuracy and may further help the implementation of PHM in the fuel cell system.