This content has 4 years. Some of the information in this post may be out of date or no longer work. Please, read this page keeping its age in your mind.

If your Android application gives the following error, when trying to use a HttpClient:

Java.IO.IOException: 'Cleartext HTTP traffic to 192.168.0.10 not permitted'

Set usesClearTraffic property to true in the AndroidManifest.xml:

<application android:label="MobileSolution.Android" 
	     android:theme="@style/MainTheme"
             android:usesCleartextTraffic="true">
		
</application>

The restriction was introduced in Android 8. More explanation: https://koz.io/android-m-and-the-war-on-cleartext-traffic/