Course Content

Course Content

WebView in Android

WebView in Android


In this video we are going to see that what is WebView.

Till now we have use different kind of layouts like Linear, Relative, Fragments etc...

If we want to add browser functionality in the application we can use WebView. It can load HTML in our application easily. To create applications that access internet connections we use WebView.

Suppose if we want to perform Google search from our application, than we can simply do that by loading WebView,






WebView will be more appropriate widget, as it can handle a much wider range of HTML tags. It also helps use JavaScript and CSS in our Android applications.

In order to load a web URL into the WebView, you need to call a method loadUrl(String url) of the WebView class, specifying the required url.

Syntax :


Apart from just loading URL you can have more control over your WebView by using the methods defined in WebView class.

WebView also has different methods like, canGoBack() to specify the webView has a back history item, canGoForward() to clear the webView forward and backward history, destroy() to destroy the internal state of webView and etc...


Recommended Courses

Share With Friend

Have a friend to whom you would want to share this course?

Download LearnVern App

App Preview Image
App QR Code Image
Code Scan or Download the app
Google Play Store
App Store
397K+ Downloads
App Download Section Circle 1
4.57 Avg. Ratings
App Download Section Circle 2
13K+ Reviews
App Download Section Circle 3
  • Learn anywhere on the go
  • Get regular updates about your enrolled or new courses
  • Share content with your friends
  • Evaluate your progress through practice tests
  • No internet connection needed
  • Enroll for the webinar and join at the time of the webinar from anywhere