Deep Linking

What is Deep Linking in Mobile Apps?

Deep Linking is a concept that helps the users to navigate between the outside digital world and specific activity in the mobile application via an intent filter system. To put it more precisely, deep links are URLs that help users navigate directly to the specific content in applications.

Here’s what the outside digital world comprises of:

  • Website
  • Another Mobile App
  • Social Media
  • Mobile Phone Search Results & Indexes
  • Advertisements
  • E-mail
  • SMS
  • WhatsApp

A URI (Uniform Resource Identifier’s) is used to deep link i.e., to define a mobile app in such a way that it will accept certain data and navigate directly to the specific content in the mobile app rather than simply starting from the first screen of the mobile app.

Why does your app need Deep Linking?

When a friend of yours shares a product link via an email/SMS/WhatsApp, you expect to look at that specific product when you click the link. If Deep Linking feature is not implemented, you might land on a generic company website. However, since the mobile app experience is richer than the browser experience, Deep Linking helps you to navigate to a particular screen in the mobile app in no time. This leads to quick conversion or purchase of products via sharing product/purchase/promo links.

Top 4 Deep Link Use Cases:

  • Invite users to signup for an app (sometimes via referral).
  • Marketing campaigns: Index your app pages with Deep Links to a certain page within your mobile app.
  • Re-engage: Use Deep links in your push notifications or email campaigns to re-engage users and increase their loyalty.
  • Omnichannel: Deep Links enable businesses to link their digital channels thoroughly.

As Deep Links point to specific content inside the app and creates an opportunity for quick conversion, it offers the action or process of earning revenue.

How Does Deep Linking work?

Deep Linking Process

How to Implement Deep Linking in Android?

Below is the full code of the Intent-filter with activity:

<activity android:name=".ExampleActivity">
    <intent-filter android:autoVerify="true">
       <action android:name="android.intent.action.VIEW" />
        <category android:name="android.intent.category.DEFAULT" />
        <category android:name="android.intent.category.BROWSABLE" /> 
        <data
            android:host="app.example.com"
            android:pathPrefix="/showProductdetails"
            android:scheme="https" />
    </intent-filter>
</activity>

Let’s see the code in detail:

When android:autoVerify is set to true, the intent filter will use its data tag for verifying the URIs.

android.intent.action.VIEW is used so that this intent filter can be reached from Google Search.

android.intent.category.BROWSABLE is used so that it is accessible from a web browser.

android.intent.category.DEFAULT is for responding to implicit intents.

All the tags from <data/> represent a URI format, which resolves the activity. You can see the host, pathPrefix & scheme tags in the above code snippet. Each tag represents a different section of the URI:

host: has the base link of the website.

pathPrefix: has the value of the prefix of the link

scheme: has the URL security section like http:// or https://

<data
 android:host="app.example.com"
 android:pathPrefix="/showProductdetails"
 android:scheme="https" />

The tags in the manifest file can be read below:

Intent intent = getIntent();
		String action = intent.getAction();
		Uri data = intent.getData();
		token = data.getQueryParameter("token");

In the above code “URI” which means Uniform Resource Identifier.

Example: https://www.example.com/demo?token=2eqdfwefjndqscjno3e3213&client=android

It’s a URL and can be counted as a Deep Link, and contains the following elements:

https: Scheme
/www.example.com: Host
/demo: Path, identifying the specific resource
?token=2eqdfwefjndqscjno3e32123&client=android: Query string with key-value pairs

URL Structure Deep Link

The first screen shows an email with a URL (structured with deep links). On clicking the URL, a choice to open the relevant app is shown.

Top 4 learning:

  • Some apps may block external navigation.
  • Have a default screen to catch all unmatched Deep Links so that at least your app with a meaningful screen would be shown to the user.
  • Validate & Test: When the app’s intents are opened to the external world via links, it becomes important to test the boundary cases. The app should not lead a link to secure screen or data.
    adb shell am start -a android.intent.action.VIEW -d “{your-uri}”
  • Attach some trackers to the URL so that Deep Links can be tracked.

Browser Link Related Issues:

  • In different devices, links are structured differently. Which means an Android link will look vastly different from an iOS link.
  • The links in the Deep Linking point to a destination, but the link doesn’t know anything about the user’s device, so it’s not a “smart” feature. Meaning if you’re on an Android device, but click on an iOS link, the device will not recognize the destination and will display an error.
  • Link on an Android device to an Android app can open either the app or Google Play Store if the app is not installed. But this is not possible in iOS, as Apple doesn’t allow a webpage to know if a specific app is installed or not. This means Apple and Google implement security in different ways.

Conclusion:

Have you ever observed that you see a mobile app screen indexed when you searched something in Google? That is because Google indexes the mobile app deep links. Deep linking is a proven way to increase your mobile app’s adoption and engagement. So, never launch the first page – always launch the product or service screen that user wants via implanting deep linking.

Evoke’s Mobility Services

At Evoke Technologies, we are committed to helping more businesses like yours discover how much they stand to gain from going mobile. We learn the ins and outs of your work to pinpoint where mobility services can make a measurable difference. With proven experience in native (iOS, Android) and cross-platform application development, our diverse range of mobile app development services enables enterprises to go mobile while keeping their long-term business goals into consideration.