This paper takes Marxist philosophy as the theoretical framework and combines the method of multiple regression analysis to explore its multidimensional role mechanism in ideological and political education. Taking the effect of ideological and political education as the dependent variable, and the three dimensions of theory arming, practice nurturing and culture leading as the independent variables, a multiple regression model is constructed to verify the six relevant hypotheses proposed in this paper. The empirical analysis shows that Marxist philosophy positively influences ideological and political education through the triple path of theoretical armament, practical nurturing and cultural leadership. The coefficients of influence of core elements such as participation in practical activities and campus culture construction on education effect are 0.236 and 0.176 respectively, constituting the main framework of the action mechanism. The study suggests to improve the effectiveness of the role from three aspects: attaching importance to the theme of education, combining practical education, and optimizing the evaluation system.