Purpose – This study examined the effect of the learning environment on students’ mathematics achievement, with student engagement as a mediator and student background as a moderator among senior high school students in Ghana. Methodology – A quantitative survey design involved 400 students from two senior high schools in the Sekondi–Takoradi Metropolis, Ghana. Data on learning environment, student engagement, and student background were collected using a structured questionnaire, while mathematics achievement scores were obtained from school records. Structural Equation Modelling (SEM) using AMOS was employed to test the hypothesised relationships. Findings – The learning environment significantly predicted student engagement and mathematics achievement. Student engagement positively affected achievement and mediated the relationship between the learning environment and mathematics achievement. Student background also moderated this relationship, with supportive backgrounds strengthening the positive effect of the learning environment on achievement. Novelty – The study integrates mediation and moderation effects within a single structural model, providing evidence on how learning environment, engagement, and background jointly influence mathematics achievement in the Ghanaian senior high school context. Significance – The findings offer useful insights for mathematics teachers, school leaders, curriculum developers, and policymakers in designing supportive learning environments, promoting active student engagement, and addressing background-related disparities in mathematics achievement.
Copyrights © 2026