Check this link: [SOLVED] How to run Blynk.run() only when WiFi connection is established it’ll do what you need…