Purpose This systematic literature review aims to identify the pattern of data mining (DM) research by looking at the levels and aspects of education. Design/methodology/approach This paper reviews 113 conference and research papers from well-known publishers of educational data mining (EDM) and learning analytics-related research using a recognized literature review in computer science by Carrera-Rivera et al. (2022a). Two major stages, planning and conducting the review, were used. The databases of Elsevier, Springer, IEEE, SAI, Hindawi, MDPI, Wiley, Emerald and Sage were searched to retrieve EDM papers from the period 2017 to 2023. The papers retrieved were then filtered based on the application of DM to the three educational levels – basic, pre-tertiary and tertiary education. Findings EDM is concentrated on higher education. Basic education is not given the needed attention in EDM. This does not enhance inclusivity and equity. Learner performance is given much attention. Resource availability and teaching and learning are not given the needed attention. Research limitations/implications This review is limited to only EDM. Literature from the year 2017 to 2023 is covered. Other aspects of DM and other relevant literature published in EDM outside the research period are not considered. Practical implications As the current trend of EDM shows an increase in zeal, future research in EDM should concentrate on the lower levels of education to identify the challenges of basic education which serves as the core of education. This will enable addressing the challenges of education at an early stage and facilitate getting a quality education at all levels of education. Appropriate EDM techniques for mining the data at this level should be the focus of the research. Specifically, techniques that can cater for the variation in learner abilities and the appropriate identification of learner needs should be considered. Social implications Content sequencing is necessary in facilitating an easy understanding of concepts. Curriculum design from basic to higher education dwells much on this. Identifying the challenge of learning at the early stages will facilitate efficient learning. At the basic level of learning, data on learning should be collected by educational institutions just as it is done at the tertiary level. This will enable EDM to accurately identify the challenges and appropriate solutions to educational problems. Resource availability is a catalyst for effective teaching and learning. The attributes of a learner will enable knowing the true nature of the learner to determine the prospects of the learner. Originality/value This research has not been published in any journal. The information presented is the original knowledge of the authors. However, a pre-print of the work is in Research Square.