Corrosion initiation and propagation are a time-series problem, evolving continuously with corrosion time, and future pitting behavior depends closely on the past. Predicting localized corrosion for corrosion-resistant alloys remains a great challenge, as macroscopic experiments and microscopic theoretical simulations cannot couple internal and external factors to describe the pitting evolution from a time dimension. In this work, a data-driven method based on time-series analysis was explored. Taking cobalt-based alloys and duplex stainless steels as the case scenario, a corrosion propagation model was built to predict the free corrosion potential (Ecorr) using a long short-term memory neural network (LSTM) based on 150 days of immersion testing in saline solution. Compared to traditional machine learning methods, the time-series analysis method was more consistent with the evolution of ground truth in the Ecorr prediction of the subsequent 70 days’ immersion, illustrating that time-series dependency of pitting propagation could be captured and utilized.