PurposeThis research aims to investigate the leadership strategies employed by two higher education institutions in Malaysia as they navigated the shift to online delivery of their computer science programs in response to the demands of Education 4.0.Design/methodology/approachA phenomenological, comparative case study approach was used to delve into the leadership and management practices of these institutions during the transition to online learning. Data were collected through interviews and document analysis.FindingsThis study explores the leadership strategies employed by two higher education institutions in Malaysia during their transition to online learning due to the COVID-19 pandemic. Five key themes emerged from the data: leadership and team coordination, training and skill development, adaptation to new assessment methods, resource management and work culture and environment. Both institutions demonstrated effective leadership, continuous training and adaptability in assessment methods. However, differences were noted in resource management and work culture. Institution A's leader had to liaise with various departments and personally invest in equipment, while Institution B was already well-equipped. The work culture at Institution A demonstrated flexibility and mutual understanding, while Institution B used key performance indicators to measure progress. Despite these differences, both leaders successfully managed the shift to online teaching, underscoring the importance of effective leadership, continuous training, flexibility, resource management and a supportive work culture in managing change. The study also highlighted the distinct roles of curriculum leaders in both institutions, with Institution A's leader focusing on multiple activities, while Institution B's leader was able to focus solely on curriculum change due to their institution's preparedness.Research limitations/implicationsThis study provides a rich, qualitative exploration of the strategies and challenges faced by program leaders in managing the shift to online teaching during the COVID-19 pandemic. Future research could build on these findings by conducting similar studies in other educational contexts or countries to compare and contrast the strategies and challenges faced by program leaders. Additionally, future research could also employ quantitative methods to measure the effectiveness of different strategies in managing the shift to online teaching. This could provide a more comprehensive understanding of the factors that contribute to successful change management in educational institutions.Practical implicationsThis study provides valuable insights for program leaders, educators and policymakers in managing change in educational institutions. The themes identified in this study – effective leadership, continuous training and skill development, flexibility in adapting to new assessment methods, effective resource management and a supportive work culture and environment – can serve as a guide for program leaders in managing future changes in their institutions. Moreover, the strategies employed by the program leaders in this study, such as forming a powerful coalition, providing training on online tools and prioritizing student welfare, can be adopted or adapted by other program leaders in managing change.Originality/valueThis study presents a unique contribution to the existing literature by offering a comparative analysis of change management strategies in two distinct educational institutions during the shift to online teaching due to the COVID-19 pandemic. It uncovers the nuanced differences in leadership styles, resource management and pedagogical adaptations, providing a rich, context-specific understanding of the change process. The study fills a research gap by examining the practical application of Kotter's 8-Step Change Model and the McKinsey 7S Model in real-world educational settings. The findings offer valuable insights for other institutions navigating similar changes, thereby extending the practical and theoretical understanding of change management in higher education.