This explored how teacher support impacted student engagement in mathematics. A total of 632 students in Grades 7 to 9 from junior middle schools in China were participants (females = 54.27%, mean age = 13.97, SD = 0.88). They completed surveys on teacher support, academic self-efficacy, achievement goal orientation, and student engagement. Data analysis was conducted using SPSS 20.0 and Amos 24.0. Results showed that academic self-efficacy mediated the relationship between perceived teacher support and student engagement. Mastery-approach and performance-approach goal orientation respectively mediated the relationship between perceived teacher support and student engagement in mathematics. Academic self-efficacy and mastery-approach had a chain mediation effect on the relationship between perceived teacher support and student engagement and academic self-efficacy. Performance-approach also had a chain mediation effect between the two. The chain mediation effect of academic self-efficacy and performance-approach was stronger than the single performance-approach effect. These findings shed light on the motivational processes through which students perceive the impact of teacher support on their engagement in mathematics.