This study aims to: (1) describe the effect of the STEM Context-based Challenge Based Learning model with gamification on students' critical thinking skills and mathematical resilience; (2) describe which is superior between the STEM Context-based Challenge Based Learning model with gamification and the Problem Based Learning model on students' critical thinking skills; (3) describe which is superior between the STEM Context-based Challenge Based Learning model with gamification and the Problem Based Learning model on students' mathematical resilience.This study is a quasi-experimental study with a pretest-posttest non-equivalent control group design. The population in this study were all seventh-grade students of SMP Negeri 1 Tegalrejo in the even semester of the 2025/2026 academic year. The sample used in this study were 30 students from classes VII-A and VII-F. Class VII-A served as the experimental class, treated with the STEM Context-based Challenge Based Learning model with gamification, and class VII-F served as the control class, treated with the Problem Based Learning model. The data collection method used was a critical thinking ability test instrument and a non-test questionnaire on students' mathematical resilience. The instruments in this study were validated using content validity with expert judgment, empirical validity tested using construct validity, and reliability estimated using the Cronbach's Alpha formula. Inferential statistical data analysis used the Hotelling's T2 test, the Independent Sample t-test, and Effect Size.The results showed that the Challenge Based Learning model based on STEM Context with gamification had an effect on students' critical thinking skills and mathematical resilience. The Challenge Based Learning model based on STEM Context with gamification was superior to the Problem Based Learning model in terms of students' critical thinking skills and mathematical resilience.