Loading...

How to Open a URL in Android Browser from Application

In this simple tutorial you will learn to open a website URL in android web browser from your own android application programmatically. Opening any website URL in web browser from android app is very simple using android intent.

Following is the simple example where I have used a button in XML layout file to open a website (URL) when button is clicked from your android application.

Code to open a specify URL in android’s web browser using android.content.Intent from your own application.

Related:
Android WebView Tutorial with Example
How to Convert Custom Website Design by Using Bootstrap into Android Application
Implement Zoom Effect in Android ImageView Images

Android Example: How to Open a URL in Android Browser from Your Application


XML Layout File


res/layout/open_url_in_android_browser.xml


Java Activity File


src/OpenURLinAndroidBrowser.java



Run your Open a URL in Android Browser from Application and click on the button to open URL in web browser.
Tutorial 1978216937540709014
Home item