Get WiFi's SSID without connecting to it?
I want to connect to a SSID wifi network in app. Code: WifiConfiguration conf = new WifiConfiguration(); conf.SSID = "\"" + networkSSID + "\""; But the problem is that I don't know the network SSID . How to get SSID of a WiFi Network without connecting to it? If you want to get all available wifi : List<ScanResult> mScanResults = mWifiManager.getScanResults(); If you want to connected wifi ssid : WifiManager wifiManager = (WifiManager) getSystemService(WIFI_SERVICE); WifiInfo wifiInfo = wifiManager.getConnectionInfo(); Log.d("wifiInfo", wifiInfo.toString()); Log.d("SSID",wifiInfo.getSSID());