Skip to content
Mobile Apps

Deep Linking and Universal Links: How to Do It Right

•
22 min read
•
Person holding smartphone with ai platform logo
Share:

A customer who taps a promotion link for your Tampa store should land on that store's booking screen, not a login wall. Universal Links let iOS hand a verified https URL straight to the installed app once your domain publishes the right association file. When that handoff breaks, the click falls back to the website and the offer is lost.

Deep linking routes a link to a specific screen inside a mobile app instead of its home page. For an operator running 10 to 150 locations, it decides whether paid search and email spend becomes booked appointments or wasted visits. Below, we cover how Universal Links and Android App Links differ, how to configure them correctly, and how to test every location before a campaign launches.

What You'll Learn

  • The difference between universal links, Android app links, custom URI schemes, and deferred deep links, and when each one fails
  • How to publish and validate the apple-app-site-association and assetlinks.json files without breaking routing
  • A fallback pattern that sends users who lack the app to the correct location page or store listing
  • How to route location-specific campaigns, bookings, and service requests to the right in-app screen
  • A pre-launch test checklist that catches broken links before paid traffic reaches them

A deep link is any link that opens a specific screen inside an app. A link to one product, one booking, or one menu item should land the user on that exact page. Without deep linking, the user lands on the app's start screen or on a website.

Three terms get mixed up:

  • Deep link is the general idea. It can use any format.
  • Universal links are Apple's version for iPhone and iPad. They use a normal web address, such as https://yourbrand.com/menu/burger. If the app is installed, iOS opens it. If not, the link opens the website.
  • App links are Google's version for Android. They work the same way and must be verified against your domain.

For the technical setup, Apple requires a verification file on your domain, described in its associated domains documentation. Android uses a similar check, covered in its app links verification guide.

A custom scheme looks like myapp://menu/burger. It only works when the app is already installed. When it fails, the phone shows an error or does nothing at all.

An HTTPS link does two jobs with one address. If the app is installed, it opens the app. If the app is missing, the same link loads the website. The customer never hits a dead end.

This matters most for links that appear in:

  1. Text messages and email campaigns
  2. Paid social and search ads
  3. Google Business Profile listings
  4. QR codes on printed material at each location

When a link opens the browser instead of the app, the customer has to start over. They search again, log in again, or give up. Each extra step is a point where people leave.

The cost multiplies across locations. A broken link on one location page sends buyers to a generic home page. Paid campaigns pay for clicks that never reach the offer. Front-desk staff then field calls from customers who cannot find their booking.

Consider a hypothetical 40-location group where 2,000 customers a month tap a promotional link. If 25 percent land on the home page instead of the offer, that is 500 people who must find the offer on their own. Across 40 locations, that is about 12 lost visits per location every month.

Teams that want this fixed once, across every location, usually need mobile app development services that cover both platforms and the web fallback in one build.

Key Insight: A standard HTTPS link is the only format that works whether or not the app is installed. Every link that drops a customer into a browser is a lost visit you already paid to earn.

Three link types can open your app from outside it. Each behaves differently on iOS and Android. Choosing the wrong one costs installs, lost leads, and support tickets at every location.

  • Universal Links (iOS): Standard web addresses that iOS routes to your app when it is installed.
  • Android App Links: The Android equivalent. They use verified HTTPS links tied to your app.
  • URI schemes: Custom addresses such as yourapp://. Any app can register the same scheme.

How they compare

FactorUniversal Links (iOS)Android App LinksURI Schemes
Setup effortModerateModerateLow
VerificationDomain file on your serverDomain file on your serverNone
App missingOpens your web pageOpens your web pageError or blank screen
Messaging app reliabilityMixedMixedOften blocked
Ownership of linkYour domainYour domainAny app can claim it

Setup and verification

Universal Links need an apple-app-site-association file on your domain. The file must load over HTTPS without redirects. The app also needs an Associated Domains entitlement. Apple lays out these steps in its supporting associated domains guide.

Android App Links need an assetlinks.json file. That file ties your domain to your app's package name and signing certificate. Google explains the check in its verify Android App Links guide.

URI schemes need only a registration in the app. Setup takes a few hours. The trade-off is that you cannot prove which app owns the scheme.

Missing app and messaging reliability

When the app is missing, a Universal Link or App Link opens your web page. That page can show the offer and an install prompt. A URI scheme fails, and the visitor often sees nothing useful.

Messaging and social platforms are the harder test. Many of them open links in their own built-in browser. A tap may never reach the native app. Custom schemes are the most likely to fail in those environments.

Recommendation for multi-location businesses

Use HTTPS links as the default. Host one verified domain. Give each location a clear path, such as /locations/tampa-north, and make every path load a real page.

Keep URI schemes for internal tools or payment returns where you control both ends.

  1. Verify the domain for iOS and Android before launch.
  2. Build a fallback web page for every location.
  3. Test each link inside the messaging and social apps your customers use.
  4. Tag every link with its location so you can measure opens by site.

Consider a hypothetical 40-location group. If each location loses one lead per week to a broken link, that is 2,080 lost leads a year. A fallback page costs far less than that. If your team lacks the bandwidth, the right service covers setup and testing, and website fallback pages keep every location's link working.

Key Insight: Use verified HTTPS links as your default, because they fall back to a working page when the app is missing. Reserve URI schemes for places where you control both ends of the link.

How to Set Up apple-app-site-association and assetlinks.json

Both files must live on the exact domain your links use. Apple reads apple-app-site-association from https://yourdomain.com/.well-known/apple-app-site-association. Android reads assetlinks.json from https://yourdomain.com/.well-known/assetlinks.json.

  • Serve each file over HTTPS with a 200 status code.
  • Use no file extension for the Apple file.
  • Set the Content-Type header to application/json.
  • Keep the file small. Apple expects a file well under 128 KB.

If you run links on www and the bare domain, host the files on both. Otherwise, one version works and the other fails silently.

Format the Apple file

The Apple file uses your Team ID and bundle ID together. Find the Team ID in your Apple Developer account under Membership. The bundle ID is the identifier in your Xcode project. Join them with a period, in the form TEAMID.com.yourcompany.yourapp.

  • Put the combined value in the appIDs list under applinks.
  • Include a components rule for each path pattern you want the app to open.
  • Check capitalization. Team IDs are uppercase, and a mismatch fails without an error message.

Apple's supporting associated domains guide lists the full key structure. Match your Xcode Associated Domains entry to the domain exactly, including the applinks: prefix.

Format the Android file

The Android file names your app's package and its signing certificate. Use the exact package name from your build.gradle file. Add the relation value delegate_permission/common.handle_all_urls so Android routes links to your app.

  • Set namespace to android_app.
  • Add the package name under package_name.
  • List the fingerprint in sha256_cert_fingerprints.

Google's Android app links verification guide covers the required fields.

Get the SHA-256 fingerprint right

The fingerprint is the most common failure point on Android. Use the certificate that signs the build users install, not only your debug key. Teams often ship a Play App Signing key that differs from their upload key.

  • Pull the fingerprint from the Google Play Console under App signing.
  • Write it in uppercase, with colons between each pair of characters.
  • Add every signing key you use, including the debug key for testing.

One wrong character breaks verification for every user. The app still installs, so the failure goes unnoticed.

Verify with the right tools

Run these checks before you release.

  1. Apple CDN check: Open Apple's validation endpoint for your domain. It shows what Apple's servers have cached.
  2. Android verification status: Run adb shell pm get-app-links your.package.name on a test device. Look for verified next to your domain.
  3. Re-verify on demand: Run adb shell pm verify-app-links --re-verify your.package.name after each file change.
  4. Google's Digital Asset Links API: Query the statements endpoint for your site and relation. It confirms that Google can read your file.

Test on a real device, not only in a simulator. Confirm that a tapped link opens the app, not the browser.

Redirect and cache mistakes that break verification

These errors do not show an error on screen. They just stop links from opening the app.

  • Redirects: A 301 or 302 on the .well-known path fails verification. This includes forced HTTP to HTTPS redirects and www to bare-domain redirects.
  • Bot protection: Firewall rules or challenge pages can return HTML instead of JSON to Apple and Google crawlers.
  • Stale CDN cache: Your CDN may serve the old file after an update. Purge the cache for the .well-known path every time you change the file.
  • Apple's device cache: iOS fetches the Apple file when the app installs. Users with older installs may need a reinstall to pick up a fix.

Test the raw URL in a private browser window. Confirm you get a 200 status and no redirect. If you need help auditing a multi-location app stack, the right service can review the setup before launch.

Key Insight: Verification fails silently, so a single redirect or stale cache can break links for every user without any warning. Test the raw file URL, the signing fingerprint, and the device-level verification status before each release.

Need help applying this to your business? Tell us about your project and we will scope it with you.

Fallback Routing When the App Is Not Installed

A customer who taps a link without your app still needs somewhere to go. If that path is broken or generic, the visit is lost. Most fallback failures are planning gaps, not technical ones. Nobody decided where a visitor without the app should land.

Route to the matching location page first

For a multi-location business, the fallback should match the location in the link. A link for your Ybor City branch should open the Ybor City page, not the home page. Set the rule once, then apply it to every location.

A sound routing order looks like this:

  1. Read the location identifier from the URL path.
  2. Confirm the matching location page exists and is live.
  3. If it does not, send the visitor to the regional or market page.
  4. Use the home page only as a last resort.

Use the store listing for app-only actions

A store listing makes sense when the goal is the app itself, such as a loyalty program or a digital service card. For booking, quoting, or reordering, the location page usually converts better because the visitor can act without installing anything.

Apple's documentation states that a universal link opens in Safari when the app is not installed, so the web page you serve is the real fallback. Read the supporting associated domains guide before you set up the domain file. Show the store button as a secondary option on that page.

Preserve campaign parameters through every redirect

Campaign tags such as utm_source, utm_medium, utm_campaign, and a location identifier must survive each redirect. When they drop out, attribution breaks and cost per acquisition cannot be read by location.

Consider a hypothetical 40-location HVAC group running one spring offer across local ads. Without preserved tags, the group cannot tell which branch produced each booking. Test every path with a tagged link before launch, and confirm the parameters appear on the final page and in your analytics.

When deferred deep linking carries the destination through install

Deferred deep linking stores the intended destination before the install, then delivers it on first open. A new user who taps a Tampa location link, installs the app, and opens it should land on that location's booking screen. Without deferral, the user lands on the onboarding splash and the link's purpose disappears.

Android handles this with a built-in signal. The Google Play Install Referrer library passes referrer data to the app after installation. iOS does not offer an equivalent Play referrer, so most teams rely on a third-party SDK or a server-side match based on device and network signals. That match is probabilistic, so plan for occasional misses.

A typical deferred flow works like this:

  1. The server stores the destination path and campaign tags when the link is tapped.
  2. The user installs the app from the store.
  3. On first launch, the app requests the stored destination.
  4. The app opens the matching location screen and records the campaign source.

Our mobile app team builds these flows for multi-location operators, including the fallback pages and attribution checks. Start with the routing rules and the parameter test, then add deferral only where a new user's first action matters most.

Key Insight: The not-installed path decides whether a tapped link becomes a visit. Route each link to its location, keep the campaign tags intact, and use deferred deep linking only where the first screen after install must match the original intent.

Routing Location-Specific Campaigns and Bookings

Most multi-location brands treat each campaign as a separate link. A spring promotion gets one URL, a plumbing ad gets another, and every branch gets its own booking page. Each offer change then means more links to build, test, and retire. A single link scheme removes most of that work.

Build the scheme around three fields. Each one answers a question the app must settle before it shows a screen.

  • Location ID answers "which branch serves this customer?" It controls hours, technician availability, and service area.
  • Service type answers "what does the customer need?" It loads the right intake questions and price list.
  • Promotion code answers "which offer applies?" It attaches a discount only when the code is valid at that location.

Keep these fields separate. A promotion should work across services, and a location should accept any valid offer. If you tie them together, you must build a new link for every combination, which recreates the sprawl you started with.

A path structure that routes cleanly

A readable path is easier to maintain than a long string of parameters. Put the location and service in the path, and put the promotion in the query string. For example:

The app opens this link directly only if the path is registered with the site. On iOS, that means listing the path in the apple-app-site-association file. On Android, the same job is done by Digital Asset Links. If either file is missing or wrong, the link opens in a browser and the customer loses the in-app booking flow.

The app should process each link in a fixed order. This keeps behavior consistent across every branch.

  1. Check the location ID against the live branch list. If the ID is retired or unknown, show a branch picker, not the home screen.
  2. Load the service intake for that branch. Hide any service the branch does not sell, so customers never start a request that cannot be fulfilled.
  3. Test the promotion against the location and service. If it fails, keep the booking open and state plainly that the offer does not apply.
  4. Save all three values with the booking record. Reporting can then split leads by branch, service, and offer.

Step four is the one teams skip. Without it, you cannot tell which location's campaign produced a booking.

Where service workflows add complexity

Field service adds a wrinkle. A customer's request often needs a diagnosis, a parts check, or a quote before a job is scheduled. The link must carry enough context to start that process, not just open a calendar slot.

Our work for Eagle Repair, a commercial equipment repair and field service business, shows this pattern. We built a custom Next.js marketing site and a client invoice portal with QuickBooks Payments integration. The site and portal move a customer from first contact through to billing in one connected system. Request routing for a service business follows the same logic.

If you need this routing inside your own product, the right service is a native iOS, Android, or React Native build. Choose the platform based on how your customers already book.

Key Insight: One link should carry the location, the service, and the offer, and the app should resolve all three before it shows a screen. Separate fields let one campaign run across every branch and service combination without new links.

Attribution answers one question: which link produced this install or this booking? For a multi-location business, the useful answer is the location and the channel, not the individual user. A link that brings a download from your Tampa branch is worth tracking. A link that follows one person across apps is not.

Every attributed event needs three things:

  1. Source: the channel, such as a Google Business Profile tap, an email, or a paid social ad.
  2. Location: the store, branch, or service area the link points to.
  3. Event: the install, the booking, or the completed order.

Which parameters to capture

Most deep link tools let you pass custom parameters in the URL. Limit them to what location-level reporting needs:

  • location_id: a short code for each site
  • channel: the traffic source
  • campaign: the internal campaign name or code
  • created_on: the date the link was generated

Do not put names, emails, phone numbers, or free-text notes in a link. URLs get written to server logs, pasted into shared messages, and stored by analytics vendors. Anything in a query string should be treated as public.

Keep the list short. Each extra field adds maintenance work and rarely changes a decision. If a field will not appear in a weekly location report, drop it.

Apple's App Tracking Transparency framework requires an app to ask permission before it tracks a user across other companies' apps and websites. Users who decline cannot be followed that way, so cross-app attribution gets weaker. Plan for those gaps instead of hoping they will not appear.

Consent rules in the EU and several US states add more limits. When a user rejects non-essential tracking, your attribution code must check that choice and stop firing. Build the check into the event layer, not a later cleanup script.

Why less data gives cleaner reports

Collecting only location-level fields lowers risk in three ways:

  • Less personal data means less to protect and fewer deletion requests to honor.
  • Fewer fields means fewer broken events after an app update.
  • Location totals stay stable, so a store manager can read them without a data analyst.

Noise is the hidden cost. A dashboard with dozens of dimensions per click buries the number a COO needs: installs or bookings per location per week. A short schema makes trends visible at a glance.

Test the setup at one location before you roll it out to all of them. Compare reported installs against that store's own booking log. If the two drift apart, fix the tagging before you expand. A team building the link and event layer can use mobile app development services to wire this in consistently across iOS and Android.

Key Insight: Capture the location, channel, and event, and nothing else, to measure deep link performance. Less data gives you lower compliance risk and a report a location manager will actually read.

Common Deep Linking Mistakes and How to Test Them

Most deep link failures are quiet. A link works in testing, then fails for a customer on a Tuesday afternoon. Four failure modes cause most of the trouble.

  1. Links open Safari instead of the app. iOS hands a link to the app only when the domain matches the associated domains entitlement and the app is installed. A typo in the entitlement, or a missing applinks entry, sends the user to the browser. The customer then sees a mobile web page instead of the screen they wanted.

  2. Stale association files. Apple's apple-app-site-association file and Android's assetlinks.json are cached by the operating system. When a bundle ID changes or a signing certificate rotates, verification can fail without any visible error. A redirect on either file is another common cause.

  3. Broken routes after app updates. A release renames a screen or changes a path pattern. Old links from email, text messages, and ads then land on an error screen. Treat every published URL as a public promise. Keep old routes mapped to new screens for as long as those links stay live.

  4. Parameters dropped by redirects. Link shorteners, ad trackers, and web-to-app redirects often strip query strings. A promo code or location ID disappears before the app opens. For a multi-location business, the location ID is often the only thing that routes a customer to the right store.

A repeatable test matrix before every release

Run the same checks before each release. Record the results in one shared sheet so every team sees the same pass or fail. The matrix below covers the platforms and apps that matter most.

Platform or appTest caseExpected result
iOS SafariTap universal link, app installedOpens app to target screen
iOS SafariTap link, app not installedOpens App Store or web fallback
Android ChromeTap App Link, app installedOpens app without chooser
Android ChromeLoad assetlinks.jsonReturns 200, no redirect
iOS MessagesLink received by textOpens app, parameters intact
Android MessagesLink received by textOpens app, parameters intact
WhatsAppTap link in chat, both OSOpens app to correct route
Instagram or FacebookTap link in in-app browserHands off to app or loads correct page
Gmail and Apple MailTap link in newsletterOpens app, query string intact

Repeat this sequence for each release:

  1. Confirm both association files return HTTP 200 on the root domain with no redirect.
  2. Run every row in the matrix on the current OS and one prior version.
  3. Log the exact URL, its parameters, and the landing screen for each test.
  4. Replay the top 20 links from last quarter's campaigns against the new build.

Teams without a device lab can outsource this work. The right service can run the matrix as part of each release, so marketing and operations never discover a broken link from a customer complaint.

Key Insight: Deep links fail after releases, not during development. A fixed matrix, run before every ship, catches the Safari fallbacks, stale files, and dropped parameters that cost multi-location businesses leads.

Sources and References

Primary sources cited above:

Share:

Free SEO & Local Visibility Audit

We read your website, and your Google Business Profile when we can match it, the way Google and AI assistants read them. Then we show you the gaps that matter most, ranked by impact, with the evidence and the exact fix for each one. Free. Enter your website and an email address, and the report is emailed to you.

Free SEO audit

Related Articles

More on this topic:

Browse the Mobile Apps hub

Take the next step

Want this in your business?

We build mobile apps systems for growing operations, without the agency-speak. Here's where to look next.

In Tampa Bay? Custom Software Development in Tampa

Frequently asked questions

What is the difference between universal links and app links?

Universal links are Apple's version for iPhone and iPad, and app links are Google's version for Android. Both use a normal https web address, so if the app is installed the operating system opens it, and if not the link opens the website. The main difference is verification: Apple checks an apple-app-site-association file on your domain, while Android checks an assetlinks.json file. Deep linking is the broader term for any link that routes to a specific in-app screen, including custom URI schemes that use non-web formats.

How do I set up universal links so they open my app instead of the browser?

Publish an apple-app-site-association file at your domain, add the associated domains entitlement in your Xcode project, and make sure the file is served over HTTPS without redirects. For Android, publish an assetlinks.json file and set autoVerify on the matching intent filters. Then test each link on a real device, since simulators and some in-app browsers behave differently. Confirm that a tap from Notes or Messages opens the app directly rather than Safari.

What happens when a customer taps a deep link but doesn't have the app installed?

The link opens the mobile web page for that same location, so the customer still reaches the right place. Your fallback should send users who lack the app to the correct location page or the store listing, not a generic homepage or a login wall. A customer who taps a Tampa promotion should land on the Tampa booking page on the web, then be offered the app download. Preserving the location and offer parameters through the install keeps the intent intact and reduces lost bookings.

Why do paid campaign deep links send traffic to the browser instead of the app?

Most failures come from misconfigured association files, redirects on the verification URL, or mismatched bundle IDs and app identifiers. When iOS can't verify your domain, the tap falls back to Safari, so paid traffic lands on a website rather than the intended in-app screen. Problems also appear when links open inside social apps or email in-app browsers that don't hand off to native apps. Fixing these at the infrastructure level protects spend at every location, not just one campaign.

How should I test deep links before launching a campaign across many locations?

Test every location's deep links on real iPhone and Android devices, both with the app installed and without it, before any paid traffic goes live. Tap each link from the channels customers will actually use, such as ads, email, and text messages, and confirm it opens the exact in-app screen for that location. Include a check that the association files are reachable and return valid JSON. Treat this like a payment flow test, with a written checklist and a sign-off step.

What are the benefits of deep linking for a multi-location business?

Deep linking sends customers straight to the screen that books, orders, or requests service for each site, so campaigns produce completed actions instead of browser visits that stall at a login or homepage. It also simplifies attribution, since each link can carry location and campaign parameters into the app. For operators running 10 to 150 locations, consistent routing means one tested pattern can scale across every store without rebuilding links for each campaign.

Join Our Free Newsletter

One short tip a week on getting found online and putting software to work. Three-minute read, plain English.

No spam. Unsubscribe anytime. We respect your privacy.