With the rapid development of the capital market, financial fraud cases are becoming increasingly common. The evolving fraud strategies pose significant threats to financial regulation, market order, and the interests of ordinary investors. In order to combine the generalization performance of different machine learning methods and improve the effectiveness of financial fraud prediction, this paper proposes a novel financial fraud prediction framework based on stacking ensemble learning. This framework, based on data from listed companies, comprehensively considers financial ratio indicators and non-financial indicators. It uses the stacking ensemble technique to integrate numerous base models of machine learning algorithms for predicting financial fraud. Furthermore, our proposed framework has high versatility and is suitable for various tasks related to financial fraud prediction, addressing the problem of model selection difficulties in previous research due to different scenarios and data. We also conduct case studies on specific companies and industries, confirming the significant interpretability and practical applicability of our proposed framework. The results show that the recall rate and Area Under Curve (AUC) of our framework reach 0.8246 and 0.8146, respectively, surpassing mainstream machine learning models such as XGBoost and LightGBM in existing studies. This research is of great significance for predicting the increasing number of financial fraud cases, providing a reliable tool for financial regulatory institutions and investors.