Docs
grovs.io Start for free

Android

Migrate your Android app from Firebase Dynamic Links to Grovs for deep linking, link generation, and more.

Before you start: you need a Grovs account and the Grovs SDK in your project. See the Android SDK guide.

Steps

1. Initialization

No explicit initialization for link handling, but Firebase itself must be initialized.

Grovs

Call Grovs.configure() in your Application class:

Kotlin
import io.grovs.Grovs
import io.grovs.model.LogLevel
 
class MainApplication : Application() {
    override fun onCreate() {
        super.onCreate()
        Grovs.configure(application = this, apiKey = "your-api-key", useTestEnvironment = false)
        Grovs.setDebug(LogLevel.INFO) // Optional
    }
}

An intent filter in AndroidManifest.xml opens links:

XML
<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:host="example.com"
        android:scheme="https"/>
</intent-filter>

Your activity reads the link:

Kotlin
Firebase.dynamicLinks
    .getDynamicLink(intent)
    .addOnSuccessListener { pendingDynamicLinkData ->
        val deepLink: Uri? = pendingDynamicLinkData?.link
        // Handle the deep link
    }

Grovs

Grovs uses similar intent filters. Take your_app_scheme, your_app_host and your_app_test_host from your Grovs project dashboard.

XML
<intent-filter>
    <data android:scheme="your_app_scheme" android:host="open" />
    <action android:name="android.intent.action.VIEW" />
    <category android:name="android.intent.category.DEFAULT" />
    <category android:name="android.intent.category.BROWSABLE" />
</intent-filter>
 
<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:scheme="https" android:host="your_app_host" />
</intent-filter>
 
<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:scheme="https" android:host="your_app_test_host" />
</intent-filter>

Add Grovs handling in onNewIntent() and onStart():

Kotlin
override fun onNewIntent(intent: Intent?) {
    super.onNewIntent(intent)
    Grovs.onNewIntent(intent, this)
}
 
override fun onStart() {
    super.onStart()
    Grovs.onStart(this)
}

Then listen for deep links with a listener:

Kotlin
Grovs.setOnDeeplinkReceivedListener(this) { deeplinkDetails ->
    // Handle the deep link
    val link = deeplinkDetails.link
    val payload = deeplinkDetails.data
}

Or with a flow:

Kotlin
Grovs.Companion::openedLinkDetails.flow.collect { deeplinkDetails ->
    // Handle the deep link
}
Kotlin
val shortLinkTask = Firebase.dynamicLinks.shortLinkAsync {
    link = Uri.parse("https://www.example.com/")
    domainUriPrefix = "https://example.page.link"
    androidParameters { }
    iosParameters("com.example.ios") { }
    socialMetaTagParameters {
        title = "Welcome to My App!"
        description = "Some social description."
        imageUrl = Uri.parse("https://www.example.com/images/social_preview.png")
    }
}.addOnSuccessListener { (shortLink, flowchartLink) ->
    // Link created
}.addOnFailureListener {
    // Error
}

Grovs

Platform parameters live in the Grovs dashboard, so the call only sets the link's content.

Kotlin
Grovs.generateLink(title = "Welcome to My App!",
                   subtitle = "Some social description.",
                   imageURL = "https://www.example.com/images/social_preview.png",
                   listener = { link, error ->
                       link?.let { link ->
                           // Link created
                       }
                       error?.let { error ->
                           // Error
                       }
                   })

Or using Kotlin coroutines:

Kotlin
try {
    val link = Grovs.generateLink(title = "Welcome to My App!",
                                  subtitle = "Some social description.",
                                  imageURL = "https://www.example.com/images/social_preview.png")
} catch (e: GrovsException) {
    // Handle generation error
}

4. User Identification and Attributes

Firebase uses FirebaseAuth for identity.

Grovs

Set identity and attributes directly:

Kotlin
Grovs.identifier = "user123"
Grovs.attributes = hashMapOf(
    "name" to "Alice Smith",
    "tier" to "Premium"
)

Running both during the transition

Grovs works alongside Firebase and Firebase Dynamic Links. You can keep both integrations for a while to phase the switch.

Last updated 2026-10-27
Was this page helpful?