STEM education has been regarded as an important educational initiative for cultivating students' twenty-first century skills. The present work aimed to explore ways to promote students' twenty-first century skills through an integrated STEM-based curriculum. Specifically, we designed and implemented an 8-week crossover program of STEM and community service education. In this program, students learned about STEM domain knowledge and community service issues. They then applied the knowledge to solve authentic problems faced by Hong Kong community-housing residents from disadvantaged groups. A mixed-method approach was employed to evaluate the effectiveness of the program in enhancing students' twenty-first century skills and attitudes, including (i) creative thinking, (ii) collaboration, (iii) perseverance, as well as their (iv) STEM career interests. The research participants were 121 secondary students from a government-subsidized school. The quantitative results showed that the participants' creative thinking, collaboration, and perseverance improved alongside their STEM career interests. These findings were further supported by the data gathered through focus-group interviews. This study provides theoretical and practical insights into the integration of STEM education with community service learning.