swiftcncontactstore

How do I open the Contacts app Swift


Is there a URL to open the contacts application from within my application? I know you can achieve this with the settings app by using the UIApplicationOpenSettingsURLString constant in Swift; however, I wasn't sure if I could do the same with the Contacts app.


Solution

  • There isn't a deep link for opening the Contacts App.

    Apple is very picky when it comes to deep-linking. They have to provide one for Settings since many apps need services like Data, Location, Bluetooth, Wifi, etc. Unfortunately they do not extend this to the Contacts App.

    However if your app needs contact information then for that Apple has provided a Contacts framework to browse through your contacts within your app itself.

    Read more about it here.

    In order to add/update/delete/merge contacts directly from your app without using the Apple's Contact UI, use the CNSaveRequest APIs. More on that here.