You need to enable JavaScript to run this app.
最新活动
大模型
产品
解决方案
定价
生态与合作
支持与服务
开发者
了解我们

iOS中访问FaceID设置的偏好设置URL Scheme是什么?(对应TouchID路径)

FaceID & Passcode Settings URL Scheme Equivalent to TouchID

Great question! The equivalent URL Scheme to access FaceID settings (paired with passcode settings, just like the TouchID one you shared) uses FACEID_PASSCODE as the root parameter instead of TOUCHID_PASSCODE.

Here's the updated Swift code example that will take users directly to the FaceID & Passcode settings screen:

if let url = URL(string: "App-Prefs:root=FACEID_PASSCODE") {
    UIApplication.shared.open(url)
}

Key Notes to Keep in Mind:

  • This works starting with iOS 11 (the first version that introduced FaceID support).
  • Apple doesn’t officially document these App-Prefs URL schemes, so there’s a slight risk they could be modified or deprecated in future iOS releases.
  • While you don’t strictly need it just to open the settings page, if your app uses FaceID functionality directly, be sure to include the NSFaceIDUsageDescription key in your Info.plist with a clear explanation of why you need it.

Quick recap: Your original TouchID code uses TOUCHID_PASSCODE — swapping that value for FACEID_PASSCODE gives you the exact equivalent for FaceID settings.

内容的提问来源于stack exchange,提问作者multiholle

火山引擎 最新活动