![Page 1: Google Searching and Linking into Your iOS app with ......Google Searching and Linking into Your iOS app with Universal Links Chaise Hocking @ChaiseHock What is App Indexing? Why do](https://reader034.vdocuments.site/reader034/viewer/2022050301/5f6a80202c50df7ca80df9ac/html5/thumbnails/1.jpg)
Google Searching and Linking into Your iOS app with Universal Links
Chaise Hocking@ChaiseHock
![Page 2: Google Searching and Linking into Your iOS app with ......Google Searching and Linking into Your iOS app with Universal Links Chaise Hocking @ChaiseHock What is App Indexing? Why do](https://reader034.vdocuments.site/reader034/viewer/2022050301/5f6a80202c50df7ca80df9ac/html5/thumbnails/2.jpg)
What is App Indexing?
![Page 3: Google Searching and Linking into Your iOS app with ......Google Searching and Linking into Your iOS app with Universal Links Chaise Hocking @ChaiseHock What is App Indexing? Why do](https://reader034.vdocuments.site/reader034/viewer/2022050301/5f6a80202c50df7ca80df9ac/html5/thumbnails/3.jpg)
Why do we need this?
![Page 4: Google Searching and Linking into Your iOS app with ......Google Searching and Linking into Your iOS app with Universal Links Chaise Hocking @ChaiseHock What is App Indexing? Why do](https://reader034.vdocuments.site/reader034/viewer/2022050301/5f6a80202c50df7ca80df9ac/html5/thumbnails/4.jpg)
Where have we seen it being used?
![Page 5: Google Searching and Linking into Your iOS app with ......Google Searching and Linking into Your iOS app with Universal Links Chaise Hocking @ChaiseHock What is App Indexing? Why do](https://reader034.vdocuments.site/reader034/viewer/2022050301/5f6a80202c50df7ca80df9ac/html5/thumbnails/5.jpg)
• Improved user experience
• Continued logged in state
• Potential for customer interaction
What do these apps gain from App Indexing?
![Page 6: Google Searching and Linking into Your iOS app with ......Google Searching and Linking into Your iOS app with Universal Links Chaise Hocking @ChaiseHock What is App Indexing? Why do](https://reader034.vdocuments.site/reader034/viewer/2022050301/5f6a80202c50df7ca80df9ac/html5/thumbnails/6.jpg)
Demo App
https://venuesnearby.com/venue/4b058744f964a5209d8722e3
https://venuesnearby.com/search?term=melbourne
![Page 7: Google Searching and Linking into Your iOS app with ......Google Searching and Linking into Your iOS app with Universal Links Chaise Hocking @ChaiseHock What is App Indexing? Why do](https://reader034.vdocuments.site/reader034/viewer/2022050301/5f6a80202c50df7ca80df9ac/html5/thumbnails/7.jpg)
![Page 8: Google Searching and Linking into Your iOS app with ......Google Searching and Linking into Your iOS app with Universal Links Chaise Hocking @ChaiseHock What is App Indexing? Why do](https://reader034.vdocuments.site/reader034/viewer/2022050301/5f6a80202c50df7ca80df9ac/html5/thumbnails/8.jpg)
Deep Link vs Universal Link
![Page 9: Google Searching and Linking into Your iOS app with ......Google Searching and Linking into Your iOS app with Universal Links Chaise Hocking @ChaiseHock What is App Indexing? Why do](https://reader034.vdocuments.site/reader034/viewer/2022050301/5f6a80202c50df7ca80df9ac/html5/thumbnails/9.jpg)
Deep Link
venuesnearby://search?term=melbourne
custom scheme
• mailto://[email protected]
• tel://1-408-555-5555
![Page 10: Google Searching and Linking into Your iOS app with ......Google Searching and Linking into Your iOS app with Universal Links Chaise Hocking @ChaiseHock What is App Indexing? Why do](https://reader034.vdocuments.site/reader034/viewer/2022050301/5f6a80202c50df7ca80df9ac/html5/thumbnails/10.jpg)
Issues with Deep Links
• Cannot open when app is not installed
• Can only be shared (email etc.)
![Page 11: Google Searching and Linking into Your iOS app with ......Google Searching and Linking into Your iOS app with Universal Links Chaise Hocking @ChaiseHock What is App Indexing? Why do](https://reader034.vdocuments.site/reader034/viewer/2022050301/5f6a80202c50df7ca80df9ac/html5/thumbnails/11.jpg)
Universal Link (iOS 9 +)
own domain
https://venuesnearby.com/search?term=melbourne
• App and website share the same link
• If app is not installed, follows the link to website
![Page 12: Google Searching and Linking into Your iOS app with ......Google Searching and Linking into Your iOS app with Universal Links Chaise Hocking @ChaiseHock What is App Indexing? Why do](https://reader034.vdocuments.site/reader034/viewer/2022050301/5f6a80202c50df7ca80df9ac/html5/thumbnails/12.jpg)
Universal Links resolve the issues of Deep Links
• Can be shared or returned in web search
• Can be distributed around the web
![Page 13: Google Searching and Linking into Your iOS app with ......Google Searching and Linking into Your iOS app with Universal Links Chaise Hocking @ChaiseHock What is App Indexing? Why do](https://reader034.vdocuments.site/reader034/viewer/2022050301/5f6a80202c50df7ca80df9ac/html5/thumbnails/13.jpg)
How do I setup App Indexing for my app?
![Page 14: Google Searching and Linking into Your iOS app with ......Google Searching and Linking into Your iOS app with Universal Links Chaise Hocking @ChaiseHock What is App Indexing? Why do](https://reader034.vdocuments.site/reader034/viewer/2022050301/5f6a80202c50df7ca80df9ac/html5/thumbnails/14.jpg)
Step 1: Satisfy Prerequisites
a. iPhone app
b. iPhone app supports routes
c. Mobile or Desktop website
![Page 15: Google Searching and Linking into Your iOS app with ......Google Searching and Linking into Your iOS app with Universal Links Chaise Hocking @ChaiseHock What is App Indexing? Why do](https://reader034.vdocuments.site/reader034/viewer/2022050301/5f6a80202c50df7ca80df9ac/html5/thumbnails/15.jpg)
Step 2: Link your app with your website AppName.entitlements
<plist version=“1.0"> <dict> <key>com.apple.developer.associated-domains</key> <array> <string>applinks:venuesnearby.com</string> <string>applinks:www.venuesnearby.com</string> </array> </dict></plist>
![Page 16: Google Searching and Linking into Your iOS app with ......Google Searching and Linking into Your iOS app with Universal Links Chaise Hocking @ChaiseHock What is App Indexing? Why do](https://reader034.vdocuments.site/reader034/viewer/2022050301/5f6a80202c50df7ca80df9ac/html5/thumbnails/16.jpg)
Step 3: Link your website with your app
{ "applinks": { "apps": [ ], "details": [ { "appID": "KADQL6585N.com.shinetech.venuesnearby", "paths": [ "/venue/*", "/search*" ] } ] }}
![Page 17: Google Searching and Linking into Your iOS app with ......Google Searching and Linking into Your iOS app with Universal Links Chaise Hocking @ChaiseHock What is App Indexing? Why do](https://reader034.vdocuments.site/reader034/viewer/2022050301/5f6a80202c50df7ca80df9ac/html5/thumbnails/17.jpg)
Step 4: Serve your association file
https://<domain>/apple-app-site-association
https://<domain>/.well-known/apple-app-site-association
• content-type: application/json
• Mustn’t be behind a redirect
• Must use an ssl certificate from a certificate authority
![Page 18: Google Searching and Linking into Your iOS app with ......Google Searching and Linking into Your iOS app with Universal Links Chaise Hocking @ChaiseHock What is App Indexing? Why do](https://reader034.vdocuments.site/reader034/viewer/2022050301/5f6a80202c50df7ca80df9ac/html5/thumbnails/18.jpg)
www.google.com/apple-app-site-association
![Page 19: Google Searching and Linking into Your iOS app with ......Google Searching and Linking into Your iOS app with Universal Links Chaise Hocking @ChaiseHock What is App Indexing? Why do](https://reader034.vdocuments.site/reader034/viewer/2022050301/5f6a80202c50df7ca80df9ac/html5/thumbnails/19.jpg)
![Page 20: Google Searching and Linking into Your iOS app with ......Google Searching and Linking into Your iOS app with Universal Links Chaise Hocking @ChaiseHock What is App Indexing? Why do](https://reader034.vdocuments.site/reader034/viewer/2022050301/5f6a80202c50df7ca80df9ac/html5/thumbnails/20.jpg)
So we’re setup…
What next?
![Page 21: Google Searching and Linking into Your iOS app with ......Google Searching and Linking into Your iOS app with Universal Links Chaise Hocking @ChaiseHock What is App Indexing? Why do](https://reader034.vdocuments.site/reader034/viewer/2022050301/5f6a80202c50df7ca80df9ac/html5/thumbnails/21.jpg)
On app installation
• The iOS fetches the apple-app-site-association file from each associated domain
• Periodically fetches file in-case of updates
/apple-app-site-association
Your WebServer
![Page 22: Google Searching and Linking into Your iOS app with ......Google Searching and Linking into Your iOS app with Universal Links Chaise Hocking @ChaiseHock What is App Indexing? Why do](https://reader034.vdocuments.site/reader034/viewer/2022050301/5f6a80202c50df7ca80df9ac/html5/thumbnails/22.jpg)
On link press
• The iOS checks each of it’s installed apps, if it has a matching domain and path
• If one matches, then it will open the link in the corresponding app
• Passes the link through to the app for action
![Page 23: Google Searching and Linking into Your iOS app with ......Google Searching and Linking into Your iOS app with Universal Links Chaise Hocking @ChaiseHock What is App Indexing? Why do](https://reader034.vdocuments.site/reader034/viewer/2022050301/5f6a80202c50df7ca80df9ac/html5/thumbnails/23.jpg)
https://venuesnearby.com/venue/4b058744f964a5209d8722e3
"paths": [ "/venue/*", "/search*" ]
"paths": [ "/venue/*", "/search*" ]
"paths": [ "/venue/*", "/search*" ]
"paths": [ "/venue/*", "/search*" ]
"paths": [ "/venue/*", "/search*" ]
![Page 24: Google Searching and Linking into Your iOS app with ......Google Searching and Linking into Your iOS app with Universal Links Chaise Hocking @ChaiseHock What is App Indexing? Why do](https://reader034.vdocuments.site/reader034/viewer/2022050301/5f6a80202c50df7ca80df9ac/html5/thumbnails/24.jpg)
So how does this help me search my app?
![Page 25: Google Searching and Linking into Your iOS app with ......Google Searching and Linking into Your iOS app with Universal Links Chaise Hocking @ChaiseHock What is App Indexing? Why do](https://reader034.vdocuments.site/reader034/viewer/2022050301/5f6a80202c50df7ca80df9ac/html5/thumbnails/25.jpg)
Some challenges, tips and common pitfalls
![Page 26: Google Searching and Linking into Your iOS app with ......Google Searching and Linking into Your iOS app with Universal Links Chaise Hocking @ChaiseHock What is App Indexing? Why do](https://reader034.vdocuments.site/reader034/viewer/2022050301/5f6a80202c50df7ca80df9ac/html5/thumbnails/26.jpg)
Challenge: Deploying locally
• Associated domain becomes your local instance of your website
• You need to serve your local website over ssl
• You must use a certificate from a certificate authority
![Page 27: Google Searching and Linking into Your iOS app with ......Google Searching and Linking into Your iOS app with Universal Links Chaise Hocking @ChaiseHock What is App Indexing? Why do](https://reader034.vdocuments.site/reader034/viewer/2022050301/5f6a80202c50df7ca80df9ac/html5/thumbnails/27.jpg)
• iOS 10 minimum
• Send the link in an iMessages
• Tap the link
Tip: Testing on the Simulator
![Page 28: Google Searching and Linking into Your iOS app with ......Google Searching and Linking into Your iOS app with Universal Links Chaise Hocking @ChaiseHock What is App Indexing? Why do](https://reader034.vdocuments.site/reader034/viewer/2022050301/5f6a80202c50df7ca80df9ac/html5/thumbnails/28.jpg)
Pitfall: Robots.txt
Allow: /apple-app-site-association
![Page 29: Google Searching and Linking into Your iOS app with ......Google Searching and Linking into Your iOS app with Universal Links Chaise Hocking @ChaiseHock What is App Indexing? Why do](https://reader034.vdocuments.site/reader034/viewer/2022050301/5f6a80202c50df7ca80df9ac/html5/thumbnails/29.jpg)
Pitfall: Device user-agent
swcd (unknown version) CFNetwork/758.2.8 Darwin/15.0.0
![Page 30: Google Searching and Linking into Your iOS app with ......Google Searching and Linking into Your iOS app with Universal Links Chaise Hocking @ChaiseHock What is App Indexing? Why do](https://reader034.vdocuments.site/reader034/viewer/2022050301/5f6a80202c50df7ca80df9ac/html5/thumbnails/30.jpg)
"paths": [ "*"]
"paths": [ "/venue/*", "/search*"] ✔
• Only allow urls your app can actually support
Tip: Defining your paths
Allow All URLs Restrict to known URLs
✘
![Page 31: Google Searching and Linking into Your iOS app with ......Google Searching and Linking into Your iOS app with Universal Links Chaise Hocking @ChaiseHock What is App Indexing? Why do](https://reader034.vdocuments.site/reader034/viewer/2022050301/5f6a80202c50df7ca80df9ac/html5/thumbnails/31.jpg)
Challenge: Limitations to path matching
• Cannot include fragments in paths
• Cannot include query parameters in paths
![Page 32: Google Searching and Linking into Your iOS app with ......Google Searching and Linking into Your iOS app with Universal Links Chaise Hocking @ChaiseHock What is App Indexing? Why do](https://reader034.vdocuments.site/reader034/viewer/2022050301/5f6a80202c50df7ca80df9ac/html5/thumbnails/32.jpg)
• Test your links in Google search response• Confirm request / response from apple-app-site-association
Tip: Debug with Charles
![Page 33: Google Searching and Linking into Your iOS app with ......Google Searching and Linking into Your iOS app with Universal Links Chaise Hocking @ChaiseHock What is App Indexing? Why do](https://reader034.vdocuments.site/reader034/viewer/2022050301/5f6a80202c50df7ca80df9ac/html5/thumbnails/33.jpg)
In Summary
• Why we should use Universal Links
• Seen it in action
• The steps to set up Universal Linking
• Some debugging advice
![Page 34: Google Searching and Linking into Your iOS app with ......Google Searching and Linking into Your iOS app with Universal Links Chaise Hocking @ChaiseHock What is App Indexing? Why do](https://reader034.vdocuments.site/reader034/viewer/2022050301/5f6a80202c50df7ca80df9ac/html5/thumbnails/34.jpg)
Thanks
iOS app https://github.com/chaisehocking/VenuesNearby
mobile web app https://github.com/chaisehocking/VenuesNearbyMWeb