All docs

Open links in your mobile app

Let links on your branded domain open your iOS or Android app, with safe web and store fallbacks, and know exactly when the setup is really active.

Updated . 3 min read.

When someone taps a short link on a phone that has your app installed, the link can open the right screen in the app instead of a web page. This works on branded domains (a paid feature), because the app and the domain have to prove they belong together.

How it works

  1. You tell Formspring which app belongs to the domain: an Apple team ID and bundle ID for iOS, or a package name and signing certificate fingerprints for Android.
  2. You list the allowed paths the app handles, such as /catalog/*. Only these paths can ever open the app. Every path needs at least two segments, so it can never collide with a short link.
  3. Formspring publishes the association files on your domain (/.well-known/apple-app-site-association and /.well-known/assetlinks.json).
  4. Formspring fetches the files back from your live domain over HTTPS and compares them with what you saved. Only then does the association read Active.

An association that was saved but not fetched back, or that sits on a domain that is not fully verified, is never shown as active, and links on it keep going to their web destination.

What a visitor gets

Visitor Result
iPhone or Android phone with the app installed and an active association The app opens on the link's app route
Phone without the app The web fallback of the link, or the App Store or Play Store page you set
Desktop The normal destination of the link

Set the route on a link with App route (for example /catalog/42), plus an optional web fallback and store addresses. A route must fall inside an allowed path of the domain, and a link with an app route cannot also have a password or a caution page, because the app link would skip them. Custom URL schemes are never used for automatic redirects; at most they are offered as a tap target on the fallback page.

Check it on a real device

A matching file proves the domain is set up correctly. It does not prove your app handles the link. Before you rely on it, test on a phone with the app installed and on one without it, on both platforms.

Not included

Formspring does not provide deferred deep linking: opening the right screen right after a fresh install needs an attribution SDK or provider in your app.

From the API and agents

Association settings are available to agents through the set_link_app_association, verify_link_app_association and delete_link_app_association tools. Links accept app_route_path, app_fallback_url, app_ios_store_url and app_android_store_url in the API and in the create_link and update_link tools.