# 深层链接

**深层链接**（Deep linking）是指直接链接到网站或移动应用内部特定、可寻址的内容，而非其顶层入口的做法。在网络上，深层链接是一种超链接，将用户带到目标网站的内页或子页面，甚至是文本文件或图像等特定资源，而不是首页<sup>[1](https://digitalcommons.wcl.american.edu/cgi/viewcontent.cgi?article=1107&context=ipbrief)</sup><sup> • </sup><sup>[2](https://link.springer.com/article/10.1007/s40319-025-01611-7)</sup>。在移动端语境中，该术语涵盖通过自定义 URI 方案、经验证的 Android App Links 或 iOS Universal Links 承载的、用于打开已安装应用内特定屏幕的链接<sup>[3](https://developer.android.com/training/app-links/create-deeplinks)</sup>。

| 关键事实 | 详情 |
|---|---|
| 定义 | 指向目标网站或应用的内页或特定资源的链接，而非首页；大多数普通网络链接在技术上都是深层网络链接<sup>[4](https://www.branch.io/resources/blog/universal-links-uri-schemes-app-links-and-deep-links-whats-the-difference/)</sup> |
| 链接分类 | 超链接分为四类：表层（简单或浅层）链接、深层链接、框架链接和内联（嵌入）链接<sup>[5](https://ink.library.smu.edu.sg/cgi/viewcontent.cgi?article=4704&context=sol_research)</sup> |
| 移动端承载方式 | Android 区分自定义深层链接（自定义 URI 方案）、网络链接（http/https）和 App Links（自 Android 6.0，即 API 级别 23 起可用的经验证网络链接）；iOS 使用 Universal Links<sup>[3](https://developer.android.com/training/app-links/create-deeplinks)</sup><sup> • </sup><sup>[6](https://developer.apple.com/library/archive/documentation/General/Conceptual/AppSearch/UniversalLinks.html)</sup> |
| 验证 | Android 从网站获取 `assetlinks.json`，并检查其 `sha256_cert_fingerprints` 是否与应用签名证书匹配；iOS 检查通过 HTTPS 无重定向提供的 `apple-app-site-association` 文件<sup>[7](https://developer.android.com/training/app-links/about)</sup><sup> • </sup><sup>[6](https://developer.apple.com/library/archive/documentation/General/Conceptual/AppSearch/UniversalLinks.html)</sup> |
| 法律地位 | 在美国，深层链接没有法律上的反对依据，法院对反链接理论持怀疑态度；2006 年丹麦的一项裁决依据丹麦版权法和营销法维持了深层链接的合法性<sup>[8](https://www.btlj.org/data/articles2015/vol16/16_3/16-berkeley-tech-l-j-1273-1344.pdf)</sup><sup> • </sup><sup>[9](https://www.sciencedirect.com/science/article/abs/pii/S0267364906000550)</sup> |
| 安全 | 自定义方案可被任何应用声明，而 Universal Links 验证仅能证明域名归属，不能证明 URL 其余部分的合法性，因此必须验证参数并将机密信息排除在链接之外<sup>[3](https://developer.android.com/training/app-links/create-deeplinks)</sup><sup> • </sup><sup>[10](https://mas.owasp.org/MASTG/best-practices/MASTG-BEST-0072/)</sup> |
| 近期变化 | Android 15 引入了动态 App Links，允许开发者在服务器端更新 `assetlinks.json` 中的深层链接规则，而无需发布新版本应用<sup>[7](https://developer.android.com/training/app-links/about)</sup> |

## 是什么让链接变得“深层”

这一区分是相对于目标的入口点而言的。表层链接指向网站首页；深层链接则越过首页，指向内页、子页面或文本文件、图像等特定资源<sup>[1](https://digitalcommons.wcl.american.edu/cgi/viewcontent.cgi?article=1107&context=ipbrief)</sup><sup> • </sup><sup>[2](https://link.springer.com/article/10.1007/s40319-025-01611-7)</sup>。按照这一定义，网络上交换的大多数链接都是深层链接：任何直接指向某条内容的 URL 都符合条件<sup>[4](https://www.branch.io/resources/blog/universal-links-uri-schemes-app-links-and-deep-links-whats-the-difference/)</sup>。该术语主要在链接绕过精心设计的入口体验时才具有分量，例如当链接方将用户引导至内页，从而在某些情况下绕开首页的广告和收入时<sup>[5](https://ink.library.smu.edu.sg/cgi/viewcontent.cgi?article=4704&context=sol_research)</sup>。

## 网络深层链接如何运作

网络深层链接不过是指向目标网站内部内容的标准 URL。历史上的争议是商业性的而非技术性的：销售首页广告的网站反对将访客直接送达内页、跳过带有广告的首页的链接<sup>[5](https://ink.library.smu.edu.sg/cgi/viewcontent.cgi?article=4704&context=sol_research)</sup>。

## 移动端深层链接

移动端深层链接必须解决网络链接不会遇到的问题：目标内容位于一个可能尚未安装的应用内部。Android 文档区分了三种类型<sup>[3](https://developer.android.com/training/app-links/create-deeplinks)</sup>：

1. **自定义深层链接**使用自定义 URI 方案，如 `example://products/123`。网站可以链接到这些方案以打开已安装的应用，不过浏览器行为可能有所不同，而且任何在其清单中声明支持同一方案的应用都可以打开该链接<sup>[3](https://developer.android.com/training/app-links/create-deeplinks)</sup><sup> • </sup><sup>[19](https://docs.expo.dev/linking/into-your-app/)</sup>。
2. **网络链接**使用标准 http 或 https URL，但未经域名验证。
3. **App Links**自 Android 6.0（API 级别 23）起可用，是经过验证的网络链接：通过网站关联，开发者向 Android 系统证明其拥有该域名<sup>[3](https://developer.android.com/training/app-links/create-deeplinks)</sup>。

**Universal Links 与 App Links。** Apple 的 Universal Links 让用户点击网站链接后无缝重定向到已安装的应用，无需经过 Safari；如果应用未安装，URL 则照常在 Safari 中打开<sup>[6](https://developer.apple.com/library/archive/documentation/General/Conceptual/AppSearch/UniversalLinks.html)</sup>。这些第二代标准在两个平台上都使用普通的 https URL：当链接经过验证并被选择由应用处理时，操作系统可以启动已安装的应用；否则 URL 仍可供浏览器使用<sup>[4](https://www.branch.io/resources/blog/universal-links-uri-schemes-app-links-and-deep-links-whats-the-difference/)</sup>。相比之下，自定义方案没有内置的后备机制，因此未安装应用的用户会看到错误页面，而且没有中央注册系统，所以可能发生 URI 冲突；Apple 还屏蔽了 [JavaScript](https://www.edgepedia.org/zh/javascript) 重定向这一变通方法<sup>[4](https://www.branch.io/resources/blog/universal-links-uri-schemes-app-links-and-deep-links-whats-the-difference/)</sup>。

**验证握手。** 在 Android 上，应用的清单在意图过滤器中以 `android:autoVerify="true"` 声明其 URL；安装时系统从 `scheme://domain/.well-known/assetlinks.json` 获取数字资产链接声明列表，该文件必须返回 HTTP 200 且 `Content-Type` 为 `application/json`，并验证文件有效且其 `sha256_cert_fingerprints` 与应用签名证书匹配<sup>[7](https://developer.android.com/training/app-links/about)</sup><sup> • </sup><sup>[11](https://developers.google.com/digital-asset-links/v1/create-statement)</sup>。经过验证的链接随后直接打开应用，不显示消歧对话框<sup>[7](https://developer.android.com/training/app-links/about)</sup>。在 iOS 上，开发者上传 `apple-app-site-association` 文件，该文件必须通过 HTTPS 无任何重定向地在 `https://<domain>/apple-app-site-association` 或 `https://<domain>/.well-known/apple-app-site-association` 可访问；应用安装后，iOS 检查此文件以确认网站允许该应用打开其 URL<sup>[6](https://developer.apple.com/library/archive/documentation/General/Conceptual/AppSearch/UniversalLinks.html)</sup>。在所引 iOS 文档描述的基于路径的匹配中，仅使用 URL 的路径部分进行比较；查询字符串和片段被忽略<sup>[6](https://developer.apple.com/library/archive/documentation/General/Conceptual/AppSearch/UniversalLinks.html)</sup>。

**路由行为。** 深层链接是 Android 通过 Intents 系统在所有版本上支持的通用能力。当链接被打开时，系统首先尝试用户为该 URI 指定的默认应用，然后尝试唯一可处理该链接的应用，否则显示消歧对话框<sup>[3](https://developer.android.com/training/app-links/create-deeplinks)</sup>。

**延迟深层链接。** 标准深层链接仅在应用已安装时才有效。延迟深层链接在应用商店安装过程中保留特定内容的上下文，并在首次安装后将用户引导至正确位置<sup>[4](https://www.branch.io/resources/blog/universal-links-uri-schemes-app-links-and-deep-links-whats-the-difference/)</sup>。归因平台依赖多种可靠性不同的匹配方法。行业基准报告显示，[Google Play](https://www.edgepedia.org/zh/google-play) Install Referrer 匹配在 Android 上为 95%至 99%，存在令牌的剪贴板匹配为 60%至 80%，一小时内指纹匹配为 65%至 85%，组合方法为 75%至 90%<sup>[12](https://tolinku.com/blog/deferred-linking-conversion-rates/)</sup>。在 iOS 上，随着 iOS 15 和 iCloud+ Private Relay 的推出，Branch 引入了通过 iOS 粘贴板（NativeLink）实现的延迟深层链接<sup>[13](https://help.branch.io/docs/branch-methodology-overview)</sup>。

## 数据说话

延迟链接性能被建模为漏斗：端到端转化率是点击安装率、安装打开率和匹配率的乘积。一个计算示例将 15%、70%和 80%相乘，得出 8.4%的点击成功解析；典型的安装打开率在 iOS 上为 65%至 80%，在 Android 上为 60%至 75%<sup>[12](https://tolinku.com/blog/deferred-linking-conversion-rates/)</sup>。

测量方式随第二代链接标准而改变。由于 Universal Links 和 App Links 立即启动应用，没有重定向链，用于网络和电子邮件营销的传统点击跟踪方法不再有效，测量必须在应用打开后追溯进行<sup>[4](https://www.branch.io/resources/blog/universal-links-uri-schemes-app-links-and-deep-links-whats-the-difference/)</sup>。当直接深层链接或安装引荐来源等确定性方法适用时，Branch 以 `+match_guaranteed=true` 标记 100%置信度的归因；iOS 14 之后，除非用户选择加入 IDFA 收集，否则该标志在安装事件上通常为假<sup>[13](https://help.branch.io/docs/branch-methodology-overview)</sup>。

使用情况在漏斗各环节并不均衡。2025 年 Branch 的一项调查发现，63%的受访者将深层链接用于用户引导，61%用于活动效果，但只有 20%用于重新激活流失用户，5%用于推荐计划<sup>[14](https://143796548.fs1.hubspotusercontent-eu1.net/hubfs/143796548/Hosted%20downloads%20for%20clients/Branch_2025_state_of_app_growth_survey_report.pdf)</sup>。在应用商店方面，Google Play 控制台报告深层链接覆盖率指标：来自开发者已验证域名的主要 URL 中被深层链接的聚合百分比<sup>[15](https://support.google.com/googleplay/android-developer/answer/12463044?hl=en)</sup>。

## 法律与政策历史

**美国案例。** Ticketmaster 与微软关于深层链接的纠纷于 1999 年 2 月和解，微软同意不再深层链接到 Ticketmaster 的网页<sup>[8](https://www.btlj.org/data/articles2015/vol16/16_3/16-berkeley-tech-l-j-1273-1344.pdf)</sup>。确立原则的案例是 *Ticketmaster Corp. v. Tickets.com, Inc.*，由美国加利福尼亚中区联邦地区法院于 2003 年 3 月 6 日判决。Tickets.com 从 1998 年起进行深层链接，直至 2001 年 7 月停止；诉状中剩余的是合同、版权和非法侵入理论<sup>[16](https://www.internetlibrary.com/pdf/Ticketmaster-Tickets.com-SJ-Motion.pdf)</sup>。关于版权理论，法院认为事实不受版权保护，超链接只是将用户转移到原告的页面，并得出结论：深层链接本身，在没有来源混淆的情况下，不构成不正当竞争<sup>[8](https://www.btlj.org/data/articles2015/vol16/16_3/16-berkeley-tech-l-j-1273-1344.pdf)</sup>。

一份法律评论报告称，反深层链接的主张在美国缺乏法律支持，法院对该理论持怀疑态度<sup>[8](https://www.btlj.org/data/articles2015/vol16/16_3/16-berkeley-tech-l-j-1273-1344.pdf)</sup>。美国法院普遍认为，超链接本身不违反《版权法》，因为不涉及复制；在 *Pearson Education, Inc. v. Ishayev* 案中，纽约联邦法院裁定，提供超链接“在没有更多行为的情况下，不足以构成侵权行为”<sup>[1](https://digitalcommons.wcl.american.edu/cgi/viewcontent.cgi?article=1107&context=ipbrief)</sup>。

**丹麦。** 在 2006 年的一项裁决中，丹麦海事和商事法院裁定，门户网站 Ofir 对房地产代理商 Home 数据库的深层链接、系统性抓取和索引是合法的，既未违反丹麦版权法，也未违反《营销法》<sup>[9](https://www.sciencedirect.com/science/article/abs/pii/S0267364906000550)</sup>。

实际的警示是合同层面的：*Tickets.com* 案中存续的合同理论表明，即使版权和不正当竞争理论不成立，网站的条款仍可被用来对抗链接方<sup>[16](https://www.internetlibrary.com/pdf/Ticketmaster-Tickets.com-SJ-Motion.pdf)</sup>。

## 安全与隐私考量

深层链接是一个攻击面，因为它们将攻击者影响的输入直接传递到应用逻辑中。OWASP 的移动安全指南指出了使其不安全的三个条件：依赖任何应用都可声明的自定义 URL 方案、未能通过域名关联验证 App Links 或 Universal Links、以及未能验证和清理传入的 URL 及其参数，从而使攻击者可控制的输入触发注入或逻辑滥用<sup>[17](https://mas.owasp.org/MASWE/MASVS-PLATFORM/MASWE-0029/)</sup>。攻击者还可以拦截深层链接中携带的令牌或个人数据，或捕获登录或密码重置链接等认证材料，导致账户被接管<sup>[17](https://mas.owasp.org/MASWE/MASVS-PLATFORM/MASWE-0029/)</sup>。

验证的一个关键局限常被误解。Universal Links 验证仅证明请求指向应用所关联的域名；它不验证 URL 的其余部分，因此任何人都可以构造指向已验证域名的、带有任意路径和查询值的链接<sup>[10](https://mas.owasp.org/MASTG/best-practices/MASTG-BEST-0072/)</sup>。未清理的参数可能导致路径遍历（例如 `path=../../private/secrets.txt` 这样的值在文件操作中逃逸预期目录）、WKWebView 中的脚本注入，以及命令或 SQL 注入<sup>[10](https://mas.owasp.org/MASTG/best-practices/MASTG-BEST-0072/)</sup>。

推荐的防御措施源于这些失败模式：仅通过经验证的 App Links 或 Universal Links 处理敏感流程，使用路径标准化和参数化查询对照允许列表验证输入，并将会话令牌和其他机密信息排除在深层链接之外，或在不可避免时使其一次性且短时效<sup>[17](https://mas.owasp.org/MASWE/MASVS-PLATFORM/MASWE-0029/)</sup><sup> • </sup><sup>[10](https://mas.owasp.org/MASTG/best-practices/MASTG-BEST-0072/)</sup>。

## 近期发展

平台行为已转向经验证的链接，远离未经验证的链接。在 [Android 12](https://www.edgepedia.org/zh/android-12) 及更高版本上，未经验证的网络链接几乎总是触发消歧对话框，这意味着它们很可能默认由用户的网络浏览器处理<sup>[3](https://developer.android.com/training/app-links/create-deeplinks)</sup>。从 [Android 15](https://www.edgepedia.org/zh/android-15) 开始，动态 App Links 允许开发者在服务器端的 `assetlinks.json` 中更新深层链接规则，而无需发布新版本应用<sup>[7](https://developer.android.com/training/app-links/about)</sup>。

在测量方面，iOS 14 之后的归因限制依然存在：在没有 IDFA 选择加入的情况下，安装事件通常无法获得确定性的保证匹配<sup>[13](https://help.branch.io/docs/branch-methodology-overview)</sup>，而 iOS 15 的 Private Relay 促使了基于粘贴板的 NativeLink 方法用于延迟深层链接<sup>[13](https://help.branch.io/docs/branch-methodology-overview)</sup>。供应商数据还表明深层链接自有媒体的使用正在增长：AppsFlyer 报告称，2024 年自有媒体转化量较 2023 年增长 64%，涵盖短信到应用、电子邮件到应用、二维码到应用和网络到应用等渠道<sup>[18](https://www.appsflyer.com/blog/trends-insights/owned-media-deep-linking/)</sup>。

## References

1. [What's All the Hype About Hyperlinking?: Connections in Copyright, Intellectual Property Brief (American University)](https://digitalcommons.wcl.american.edu/cgi/viewcontent.cgi?article=1107&context=ipbrief)
2. [Technological Neutrality, Hyperlinking and Criminal Liability, Springer (2025)](https://link.springer.com/article/10.1007/s40319-025-01611-7)
3. [Create deep links, Android Developers](https://developer.android.com/training/app-links/create-deeplinks)
4. [Universal Links vs. URI Schemes vs. App Links: What's the Difference?, Branch](https://www.branch.io/resources/blog/universal-links-uri-schemes-app-links-and-deep-links-whats-the-difference/)
5. [Linking on the Internet and copyright liability, SMU School of Law research](https://ink.library.smu.edu.sg/cgi/viewcontent.cgi?article=4704&context=sol_research)
6. [Support Universal Links, App Search Programming Guide, Apple Developer](https://developer.apple.com/library/archive/documentation/General/Conceptual/AppSearch/UniversalLinks.html)
7. [About App Links, Android Developers](https://developer.android.com/training/app-links/about)
8. [Link Law Revisited, Berkeley Technology Law Journal](https://www.btlj.org/data/articles2015/vol16/16_3/16-berkeley-tech-l-j-1273-1344.pdf)
9. [Clearing the legal barriers: Danish court upholds 'deep linking' in Home v. Ofir, Computer Law & Security Review (2006)](https://www.sciencedirect.com/science/article/abs/pii/S0267364906000550)
10. [MASTG-BEST-0072: Validate Input Parameters in Universal Link Handlers, OWASP Mobile Application Security](https://mas.owasp.org/MASTG/best-practices/MASTG-BEST-0072/)
11. [Creating a Statement List, Google Digital Asset Links](https://developers.google.com/digital-asset-links/v1/create-statement)
12. [Deferred Deep Linking Conversion Rates: Benchmarks, ToLinku](https://tolinku.com/blog/deferred-linking-conversion-rates/)
13. [Branch Methodology Overview, Branch Help Center](https://help.branch.io/docs/branch-methodology-overview)
14. [Branch State of App Growth Survey Report 2025](https://143796548.fs1.hubspotusercontent-eu1.net/hubfs/143796548/Hosted%20downloads%20for%20clients/Branch_2025_state_of_app_growth_survey_report.pdf)
15. [Verify and maintain deep links, Play Console Help](https://support.google.com/googleplay/android-developer/answer/12463044?hl=en)
16. [Ticketmaster Corp. v. Tickets.com, Inc., 2003 U.S. Dist. LEXIS 6483 (C.D. Cal. March 6, 2003)](https://www.internetlibrary.com/pdf/Ticketmaster-Tickets.com-SJ-Motion.pdf)
17. [MASWE-0029: Insecure Deep Links, OWASP Mobile Application Security](https://mas.owasp.org/MASWE/MASVS-PLATFORM/MASWE-0029/)
18. [Owned media & deep linking drive record growth, AppsFlyer](https://www.appsflyer.com/blog/trends-insights/owned-media-deep-linking/)
19. [Linking into your app](https://docs.expo.dev/linking/into-your-app/)

---
*Initially written Sep 17, 2026 · Reviewed: Oct 15, 2026 · Edited: Oct 15, 2026 · Last review: Oct 15, 2026*

Topic: 技术与人造世界 › 计算技术与数字系统 › 网络与安全 › HTTP and web communication protocols

Copyright 2026 Edgepedia

License: Edgepedia Community License 1.0, https://www.edgepedia.org/edgepedia/license

Source: https://www.edgepedia.org/zh/deep-linking

English original: https://www.edgepedia.org/deep-linking
