The development of information technology has promoted the reform of ideological and political education in colleges and universities. A large amount of data has been accumulated in the education management database, and the information implied by these data can provide scientific guidance for the optimization of educational management strategies in colleges and universities. The relationship and characteristics of big data in ideological and political education in colleges and universities were expounded, and the feasibility of applying big data technology to ideological and political education was analyzed. The k-means algorithm was selected for cluster analysis, and its process and principles were expounded. As the traditional k-means clustering algorithm has low data processing efficiency and large deviation of the results, the algorithm was optimized by controlling the iterative method of the algorithm. Besides, the ideological and political education management under the optimized k-means algorithm was established. The work assessment quantitative scale in the management of ideological and political education was adopted as the data source, and the optimized k-means algorithm was used to carry out cluster analysis. The results show that management attitude was scored as 0.634, the management ability was 0.6092, the management effect was 0.6082, and the management method was 0.5792. It was indicated that all the scores were above the middle for greater than 0.5, suggesting that the overall management level was above the middle, which was relatively good. The optimized k-means-based ideological and political education management strategy model can analyze the current educational management status of colleges and universities more accurately. It can also provide scientific guidance for colleges and universities to conduct teaching management reasonably and scientifically according to the data analysis results. The optimized k-means algorithm was compared with the traditional algorithm, from which the optimized algorithm was obviously better than the traditional algorithm in terms of clustering effect and operation stability.