In the age of intelligence, information technology (IT) education has become the focus of attention in the education sector. However, traditional teaching methods fall short in motivating students and fostering higher-order thinking and have difficulty providing a personalized learning experience. Although AI chatbots can provide instant feedback as an innovative teaching tool, it is still challenging to fully enhance learner engagement. Based on this, this study developed a digital game-based AI chatbot system to enhance students’ learning experience through digital game-based learning strategies. This study utilized a quasi-experimental design with the experimental group using a digital game-based AI chatbot and the control group using a traditional AI chatbot. A comparison was made between the two groups concerning student learning performance in IT courses, higher-order thinking (including problem-solving, computational thinking, and creativity), learning motivation, and flow experience. In addition, the behavioral patterns of high-achieving and low-achieving students in the experimental group were analyzed. The results showed that the experimental group was significantly better than the control group in academic performance, problem-solving, computational thinking, learning motivation, and flow experience, but there was no significant difference in creativity tendency. Behavioral pattern analysis showed that high-achieving students in the experimental group showed more systematic learning strategies, while low-achieving students relied more on immediate feedback and external help, but both high- and low-achieving groups were able to actively talk to the AI chatbot and actively explore problem-solving strategies in the digital game. Therefore, AI chatbots based on digital games can be effectively used in IT courses to help students construct knowledge and develop higher-order thinking.