I included the proper app links metatags in the HTML, so that by clicking on that link on Facebook the Android and iOS apps would open with the correct content.
This is an example of page: https://trenit.info/L2o
<meta property="al:ios:url" content="https://trenit.info/L2o" />
<meta property="al:ios:app_store_id" content="1058908183" />
<meta property="al:ios:app_name" content="Trenit!" />
<meta property="al:android:url" content="https://trenit.info/L2o" />
<meta property="al:android:app_name" content="Trenit!" />
<meta property="al:android:package" content="eu.baroncelli.oraritrenitalia" />
I published that link on Facebook, and I have installed the Trenìt! app in both my Android and iOS devices.
on iOS:
if I use the Facebook app and click on that link, the Trenìt! iOS app opens correctly with that content.
on Android:
If I use the Facebook app and click on that link, the HTML page opens instead of the Trenìt! Android app.
am I doing something wrong?
Please note, on the Android manifest I have already specified this intent filter:
<intent-filter>
<action android:name="android.intent.action.VIEW" />
<category android:name="android.intent.category.DEFAULT" />
<category android:name="android.intent.category.BROWSABLE" />
<data android:scheme="https" android:host="trenit.info" />
</intent-filter>
In android to open your app from external link/sms.., you have to use deep link in your app. so that your app will be shown in the choose launcher dialog, where you can choose your app to open
Please follow below developers link
https://developer.android.com/training/app-indexing/deep-linking.html
This below xml is just for understanding. Please change accordingly