question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

WhatsApp app opens automatically in iOS but not in latest Android (11 and 12), using a web uri

See original GitHub issue

Bug description:

The following URL does NOT open the WhatsApp app automatically in Android 11 and Android 12 (while it DOES in iOS and Android 10 and below): https://api.whatsapp.com/send?phone=9005370455720&text=Please send us your details

Instead, it shows the following message: “looks like you don’t have whatsapp installed” (while we do have the whatsapp app installed)

Interestingly, it opens the WhatsApp app in a version of our app that uses an older version of react-native-webview (and react-native): “react-native-webview”: “^10.10.2”

To Reproduce:

Just use this URI to see that the WhatsApp app opens automatically in iOS but not in latest Android (11 and 12): https://api.whatsapp.com/send?phone=9005370455720&text=Please send us your details

Expected behavior:

The WhatsApp app should open automatically in latest Android (11 and 12), like it does for all IOS versions and Android 10-.

Environment:

  • OS: Android
  • OS version: 11 & 12
  • react-native version: “^0.66.1”,
  • react-native-webview version: “^11.14.2”

Issue Analytics

  • State:closed
  • Created a year ago
  • Reactions:3
  • Comments:7

github_iconTop GitHub Comments

3reactions
SaharTocommented, Jul 31, 2022

[Solved] - In my case the WhatsApp link works fine outside of the application and on the web. but when I’m using it inside the application webView it’s not working and show me screen that says “WhatsApp is not install on this phone” although it is.

So I look for the WhatsApp api domain to give it permission on my app…

solution: Inside the AndroidManifestt.xml add this:

<queries>
    <intent>
      <action android:name="android.intent.action.VIEW" />
      <data android:scheme="https" android:host="api.whatsapp.com"/>
    </intent>
  </queries>

It will allow the app to enter this domain… 🫡🤓

1reaction
amingsccommented, May 27, 2022

meet the same issue, test with this uri: https://y.music.163.com/m/song?app_version=8.7.55&id=1364400123&uct=jvo9gcfEZ26Mjrz55/IF4g%3D%3D&dlt=0846

found the problem, insecure resource not allowed,fix: mixedContentMode={'always'}

actually the guide for debugging is useful, it will help you find many problems👈🏻IMPORTANT

Read more comments on GitHub >

github_iconTop Results From Across the Web

Permissions updates in Android 11 - Android Developers
One-time permissions; Auto-reset permissions from unused apps ... Starting in Android 11, whenever your app requests a permission related to location, ...
Read more >
html - Sharing link on WhatsApp from mobile website (not ...
Just saw it on a website and seems to work on latest Android with latest chrome and whatsapp now too! Give the link...
Read more >
Can't connect to WhatsApp | WhatsApp Help Center
Open your device's Settings > tap Network & internet > Internet. Next to your carrier, tap the Settings icon. Turn Mobile data on....
Read more >
iOS 16 - Apple
iOS 16 brings all-new personalized Lock Screens, Focus filters, Shared Photo Library, and game-changing messaging features to iPhone.
Read more >
Everything a developer needs to know about deep linking
There is no data passage through the app store – except on Android, with the Play Store Receiver. ... All web URLs that...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found