The invention discloses a method for ensuring the security of a local operating environment of a financial App, which is characterized by comprising the following steps of: A, judging whether a started App is the financial App or not, and if so, detecting the operating environment; b, entering a site cleaning mode and executing site cleaning operation; c, executing different site clearing operations according to the state of the application, such as temporarily quitting a site clearing mode, restarting the site clearing mode, clearing a background financial App and the like; and D, completelyquitting the site cleaning mode. According to the method, the state of the App is monitored, the financial App is matched according to the package name of the App, and the site clearing strategy is started; when the financial App is started, the operation environment is detected, and the site clearing operation is executed, so that the financial App operates in the site clearing mode, and the useof the financial App and the safety of financial transactions are ensured. By using the System Server, an external interface is not exposed, and the attack difficulty of the method is improved. Therefore, the method has the advantages that the security of the local operation environment of the financial App is improved, the attacked risk is reduced, and the financial security is protected.