I'm trying to send an email with deep linking to my iOS app, using myapp:// format to open it up from email. It works (i.e. tapping on it opens the app) in any iOS mail client (Mail, Mailbox, etc.) but not in Gmail app (or even web), that strips it out leaving text only. Does anyone has a solution/alternative beside creating a web link that redirects then from browser to app?
iOS deep linking is stripped out in Gmail
Asked Answered
"iOS" need not be in the title... Android deep linking is exactly the same thing, and suffers from the same issue. –
Hagride
Nope, unfortunately Gmail detects non-http/https protocols in links and strips the anchor () tag (so using data: or javascript: to perform a redirect is out too).
If/When Google implements Actions on Gmail for iOS/Android, those may work (https://developers.google.com/gmail/actions/actions/actions-overview), but as of now, they are not rendered on native mobile clients.
My solution was to put a normal http(s) endpoint on my server that will redirect to the deeplink
app://...
url. –
Circumstance Thanks Michael... This solution works perfectly. Sometimes the most primitive solution is best... –
Prelate
Then it has to open the browser as an intermediary, rather than going straight to your app? –
Kilgore
yes @Kilgore same here. Is there any way it can go to app directly ? –
Harlamert
above method will open app if it is installed, but how can I handle request if app is not installed on users device. –
Volteface
While @Michael's solution of redirect works, it remains broken on iOS if the user tries to open the link in Chrome on iOS. I know... who does that, right? But just putting it out there for others to save time :-) –
Quenby
You can create a server with a regular endpoint that will redirect to the "special" myapp://
link.
If you are running Node + Express, here's an example of a middleware that does exactly that:
© 2022 - 2024 — McMap. All rights reserved.