Fix cleartext network call error on Android 9 / API 28+

Open AndroidManifest.xml

In the application tag, add this attribute

android:usesCleartextTraffic="true"

If this doesn’t work, also add these tags

<uses-library android:name="org.apache.http.legacy" android:required="false"/>
<uses-library android:name="org.apache.http.legacy" android:required="false"/>

Also published on Medium.

By |2019-04-02T17:08:53+00:00March 14th, 2019|Categories: Android Tutorials|Tags: , |0 Comments

Leave A Comment