Android webview slow
It depends on the web application being loaded. Try some of the approaches below:
Set higher render priority (deprecated from API 18+):
webview.getSettings().setRenderPriority(RenderPriority.HIGH);
Enable/disable hardware acceleration:
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.KITKAT) {
// chromium, enable hardware acceleration
webView.setLayerType(View.LAYER_TYPE_HARDWARE, null);
} else {
// older android version, disable hardware acceleration
webView.setLayerType(View.LAYER_TYPE_SOFTWARE, null);
}
Disable the cache (if you have problems with your content):
webview.getSettings().setCacheMode(WebSettings.LOAD_NO_CACHE);
Adding this android:hardwareAccelerated="true"
in the manifest was the only thing that significantly improved the performance for me
More info here: http://developer.android.com/guide/topics/manifest/application-element.html#hwaccel