In the automatic welding process on mid/thick plates, the precision of the welding position has an important effect on welding quality, which mainly relies on the identification of the welding seam. However, due to some possible disturbances in complex unstructured welding environments, e.g., strong arc lights, welding splashes, thermal-induced deformations, etc., it is a great challenge to identify the welding seam. In this paper, we propose a robust automatic welding seam identification and tracking method by utilizing structured-light vision. First, after the preprocessing of the welding image, the gray distribution of the laser stripe is tracked and the profile of the welding seam is searched in a small area by using the Kalman filter, with the aim to avoid some disturbances. Second, in order to extract the welding seam profile, a series of centroids obtained by scanning the columns in the rectangular window are fitted using the least-squares method. Third, a character string method is proposed to qualitatively describe the welding seam profile, which might consist of different segment and junction relationship elements. And then, these character strings acquired from the object image are matched with those from the model, so that the position of the welding seam can be determined. Finally, the advantages of the new algorithm are testified and compared through several experiments.