title: Android App link - Open a url from app in browser without triggering App Link
body: <p>I have enabled App linking in my application. It works fine. But in my application there are some scenarios where i cannot handle the incoming url. In those cases i want to redirect that url to the default browser in the device. </p>
  
  <p>Currently what i have tried doing is using intents to open browser with the url, but it again redirects to my app itself. The app link is of the format -> </p>
  
  <pre><code>https://&lt;domain&gt;/&lt;prefix&gt;/&lt;params&gt;
  </code></pre>
  
  <p>so depending on the params, i would like to either handle the app link in the app itself or redirect it to the default browser. Below is the code i tried to open the browser with the above url</p>
  
  <pre><code>val browserIntent = Intent(Intent.ACTION_VIEW, Uri.parse(appLinkModel.url))
  browserIntent.addCategory(Intent.CATEGORY_APP_BROWSER)
  browserIntent.resolveActivity(packageManager)?.let {
      startActivity(browserIntent)
  }
  </code></pre>
  
  <p>I tried excluding the addCategory() line but the results are the same. Either the app crashes(hence the resolveActivity()), or app opens itself in a loop. </p>
  
  <p><strong>WHAT I WANT TO DO</strong></p>
  
  <p>So what i want to do is redirect the url to the default browser(or show a chooser <strong>WITHOUT</strong> my app in it), without triggering the app link again and again. So is this possible? </p>