The invention relates to an iOS network testing strategy comprising the following steps: step 1, setting whether the current operating environment is an online environment; if the current operating environment is the online environment, allowing an APP to connect a server, and if the current operating environment is not the online environment, then prohibiting the APP from connecting the server; step 2, setting whether to enable a testing mode; if the testing mode is enabled, only allowing the connection to a testing server, and if the testing mode is not enabled, only allowing the connectionto a formal server; step 3, when the connection to the testing server is allowed, requesting a testing domain name analysis table; in the case of request success, analyzing the obtained testing domainname analysis table, and in the case of request failure, returning error information; and step 4, after the analysis is completed, generating and outputting a local testing domain name mapping. The iOS network testing strategy provided by the invention can avoid the situation that the APP is not switched to the formal server in time after being formally issued to automatically sett the conditionsof the server corresponding is avoided, the influence to the normal service is avoided as much as possible, the development is facilitated, the APP is tested, and the testing risk is reduced.