Android App Links配置后浏览器无法跳转至Flutter应用求助
Android App Links无法正常跳转问题排查
我遇到了Android App Links无法正常工作的问题,已耗费5天时间排查。
已执行操作
- 将
assetlinks.json上传至gifthub.kr主机,可通过https://gifthub.kr/.well-known/assetlinks.json访问,文件包含Play Console、debug.keystore及上传密钥库的三个SHA256指纹,Content-Type为application/json。 - 通过
flutter run安装应用后,在Chrome中打开https://gifthub.kr/giftcards/deeplink无法跳转至应用。 - 考虑到debug模式可能存在问题,通过
flutter build apk构建release包并经Firebase Distribution安装到真机,问题仍存在。 - 使用adb命令测试:
adb shell am start -W -a android.intent.action.VIEW -d "https://gifthub.kr/giftcards/deeplink",应用可正常打开。
自我判断
- assetlinks.json部署注册正确
- URL与应用关联正常
但浏览器中App Links仍无法跳转,以下是相关文件及检查情况:
AndroidManifest.xml配置
包含flutter_deeplinking_enabled元数据及正确的intent-filter,指定了http/https scheme、gifthub.kr主机及对应pathPattern。
assetlinks.json内容
正确配置了应用包名、三个SHA256指纹及权限关联。
已完成检查
- assetlinks.json可正常访问且格式正确
- AndroidManifest.xml的intent-filter和元数据配置符合Flutter文档要求
- 仅存在一个
android.intent.action.VIEW的intent-filter - App Links Assistant验证URL可正确映射至.MainActivity
- assetlinks.json的MIME类型为
application/json
内容的提问来源于stack exchange,提问作者seheon
相关产品推荐
相关产品推荐

