How to detect when WIFI Connection has been established in Android?
You can register a BroadcastReceiver to be notified when a WiFi connection is established (or if the connection changed). Register the BroadcastReceiver: IntentFilter intentFilter = new IntentFilter(); intentFilter.addAction(WifiManager.SUPPLICANT_CONNECTION_CHANGE_ACTION); registerReceiver(broadcastReceiver, intentFilter); And then in your BroadcastReceiver do something like this: @Override public void onReceive(Context context, Intent intent) { final String action = intent.getAction(); if (action.equals(WifiManager.SUPPLICANT_CONNECTION_CHANGE_ACTION)) { … Read more