Choose Contact Emails Without Address Book Access

Your app needs an email address for a shared shopping list. It does not need the user’s dentist, three former landlords, and someone saved as “Plumber maybe.”

That sounds like a limited-contacts-permission problem. Sometimes it is. Sometimes the app only needs a system picker to return one deliberately chosen value.

A Stack Overflow question from March, still unanswered when checked on September 30, asks how to obtain specific contacts without requesting full access, and whether ContactAccessButton helps if full permission already exists. The useful answer starts by separating selection from authorization.

Let’s build a small recipient shortlist, then identify where the newer access button belongs.

Choose the contract before the API

What the feature needsStart here
One email address someone picks nowCNContactPickerViewController
Contacts the app can fetch again laterCNContactStore with the person’s authorization
A search flow that incrementally grants ongoing accessContactAccessButton, available from iOS 18
A system interface for adjusting the shared contactscontactAccessPicker, available from iOS 18

Apple documents that CNContactPickerViewController does not require contacts access or present the general permission prompt. It returns the person’s final selection. This capability dates to iOS 9; it did not arrive with limited authorization.

That makes it a good fit for an explicit, one-off recipient choice. The sample below does not request authorization or fetch the address book. It copies the chosen email into local view state.

For ongoing access, iOS 18 added a different set of tools. Apple’s ContactAccessButton can grant access incrementally. It does not appear when the app already has full authorization. Full permission tells us what the app may read; it does not tell us whom the person wants to invite.

Keep a separate shortlist either way. A permission grant is not a guest list.

Store the chosen property, not a Contacts object

A person can have several email addresses. We want them to choose the address, rather than silently taking the first one.

The complete example targets iOS 18 or later and uses Swift 6.2 or later. Start with these value types. An entry’s identity combines the contact identifier with the chosen labeled property’s identifier. Selecting the same property again updates its snapshot in place; selecting another address adds another entry.

import Foundation

nonisolated struct PickedEmail: Identifiable, Equatable, Sendable {
    struct ID: Hashable, Sendable {
        let contact: String
        let property: String
    }

    let id: ID
    let name: String
    let address: String
}

nonisolated struct RecipientShortlist: Sendable {
    private(set) var entries: [PickedEmail] = []

    mutating func add(_ entry: PickedEmail) {
        if let index = entries.firstIndex(where: { $0.id == entry.id }) {
            entries[index] = entry
        } else {
            entries.append(entry)
        }
    }

    mutating func remove(at offsets: IndexSet) {
        for index in offsets.sorted(by: >) {
            entries.remove(at: index)
        }
    }
}

Apple describes CNContact.identifier as identifying a contact on the device. Here we use it for the current shortlist. Do not turn it into a global person identifier or an app account ID.

Two contact cards can contain the same email. We deliberately do not merge those cards here, or lowercase the entire address and pretend to have solved email identity. If the eventual invitation endpoint needs duplicate suppression, give it an explicit policy and test that separately.

Wrap the system picker

Add the following below the model. It uses SwiftUI to present the UIKit picker, and returns either one email snapshot or nil for cancellation.

import SwiftUI
import Contacts
import ContactsUI

@MainActor
struct EmailContactPicker: UIViewControllerRepresentable {
    let onFinish: (PickedEmail?) -> Void

    func makeCoordinator() -> Coordinator {
        Coordinator(onFinish: onFinish)
    }

    func makeUIViewController(context: Context) -> CNContactPickerViewController {
        let picker = CNContactPickerViewController()
        picker.delegate = context.coordinator
        picker.displayedPropertyKeys = [CNContactEmailAddressesKey]
        picker.predicateForEnablingContact = NSPredicate(
            format: "emailAddresses.@count > 0"
        )
        picker.predicateForSelectionOfContact = NSPredicate(value: false)
        picker.predicateForSelectionOfProperty = NSPredicate(
            format: "key == %@", CNContactEmailAddressesKey
        )
        return picker
    }

    func updateUIViewController(
        _ picker: CNContactPickerViewController,
        context: Context
    ) {
        context.coordinator.onFinish = onFinish
    }

    @MainActor
    final class Coordinator: NSObject, @MainActor CNContactPickerDelegate {
        var onFinish: (PickedEmail?) -> Void

        init(onFinish: @escaping (PickedEmail?) -> Void) {
            self.onFinish = onFinish
        }

        func contactPickerDidCancel(_ picker: CNContactPickerViewController) {
            onFinish(nil)
        }

        func contactPicker(
            _ picker: CNContactPickerViewController,
            didSelect property: CNContactProperty
        ) {
            guard property.key == CNContactEmailAddressesKey,
                let propertyID = property.identifier,
                let address = property.value as? String,
                !address.isEmpty
            else {
                onFinish(nil)
                return
            }

            let contact = property.contact
            let nameKeys = CNContactFormatter.descriptorForRequiredKeys(
                for: .fullName
            )
            let formattedName = contact.areKeysAvailable([nameKeys])
                ? CNContactFormatter.string(from: contact, style: .fullName)
                : nil
            let name = formattedName.flatMap { $0.isEmpty ? nil : $0 } ?? address

            onFinish(PickedEmail(
                id: .init(contact: contact.identifier, property: propertyID),
                name: name,
                address: address
            ))
        }
    }
}

There are three separate picker decisions here:

  1. Enable only contacts with an email address.
  2. Open the contact’s detail card rather than returning the whole contact immediately.
  3. Return the selected email property rather than performing its default action.

Those behaviors come from the picker’s selection predicates. Set them before presentation. Returning false from the contact-selection predicate is intentional: even a contact with two nearly identical addresses deserves an explicit choice.

The coordinator and its delegate conformance are explicitly MainActor-isolated. The isolated conformance restricts its use in Swift to MainActor, matching this UIKit callback path even though the imported delegate requirements are not actor-annotated. The annotation does not dispatch callbacks onto an actor.

The coordinator implements the singular property delegate callback. Adding a plural selection callback changes the picker to a multiselection workflow; that is a different interaction to design and test.

Contacts objects can contain only some available keys. Before asking the formatter to construct a name, we check its required-key descriptor. The chosen email is a useful fallback. We then discard the framework object and keep a small value snapshot.

Present a shortlist with an ordinary sheet

This view completes the example. Put RecipientShortlistView() in an iOS app’s existing window or navigation destination.

@MainActor
struct RecipientShortlistView: View {
    @State private var shortlist = RecipientShortlist()
    @State private var showingPicker = false

    var body: some View {
        NavigationStack {
            List {
                Section {
                    Button("Choose an email from Contacts") {
                        showingPicker = true
                    }
                }

                Section("Selected recipients") {
                    if shortlist.entries.isEmpty {
                        Text("Choose someone to add to this list.")
                            .foregroundStyle(.secondary)
                    }
                    ForEach(shortlist.entries) { entry in
                        VStack(alignment: .leading, spacing: 4) {
                            Text(verbatim: entry.name)
                            Text(verbatim: entry.address)
                                .font(.subheadline)
                                .foregroundStyle(.secondary)
                        }
                    }
                    .onDelete { offsets in
                        shortlist.remove(at: offsets)
                    }
                }
            }
            .navigationTitle("Recipients")
            .toolbar { EditButton() }
            .sheet(isPresented: $showingPicker) {
                EmailContactPicker { entry in
                    if let entry { shortlist.add(entry) }
                    showingPicker = false
                }
            }
        }
    }
}

Cancelling leaves the shortlist alone. Removing a row removes the local snapshot; it does not delete a contact or change the app’s authorization. The example sends nothing and intentionally keeps the shortlist only for this view’s lifetime.

For this picker-only workflow, do not add a preliminary requestAccess call. Apple explicitly supports selection without that permission. If another part of your app reads the contact store, that separate functionality still needs the appropriate authorization and NSContactsUsageDescription configuration.

A copied email can become stale after the person edits their contact card. Do not retain the returned identifier and assume it gives you permission to refresh the contact later. For a saved draft, show the copied address again before sending; for a continuously synchronized contact feature, choose the ongoing-access contract instead.

Where ContactAccessButton earns its place

Suppose the feature changes: the app now maintains contact-linked people and refreshes their details. A search-based grant flow makes sense.

Before running this authorization-granting variant, configure NSContactsUsageDescription in the app target with a clear explanation of the ongoing contact feature. This separate, complete component compiles on iOS 18 and later. Its callback deliberately says onAccessGranted, not onRecipientsSelected:

@available(iOS 18.0, *)
@MainActor
struct ContactAccessSearch: View {
    @State private var query = ""
    let onAccessGranted: ([String]) -> Void

    var body: some View {
        VStack(alignment: .leading, spacing: 16) {
            TextField("Search contacts to share with this app", text: $query)
                .textFieldStyle(.roundedBorder)
            ContactAccessButton(queryString: query) { identifiers in
                onAccessGranted(identifiers)
            }
            .contactAccessButtonCaption(.email)
        }
        .padding()
    }
}

Apple’s WWDC24 explanation covers an especially useful detail: the button can be presented while authorization is still undetermined. A tap can initiate a simplified limited-access prompt. You do not need to ask for full access first.

The system owns the button’s private contact results. Keep it legible, unobscured, and large enough to render; it is not a custom row whose contents your app may inspect before a grant. The email caption changes the presentation, not the callback’s contract. That callback contains contact identifiers, not the selected email addresses.

In an ongoing-access feature, use those identifiers to fetch the fields you need, then present your own explicit recipient choice. Configure NSContactsUsageDescription before adopting contact-store access. Handle denied or restricted access and later changes in Settings. Do not interpret newly granted IDs as the complete set of accessible contacts or as a command to send invitations.

If full authorization already exists, the access button disappearing is expected. The ordinary picker still gives the person a way to choose a recipient. There is no need to enumerate the whole address book just because permission would allow it.

Verify the decision, not just the happy path

The model checks cover repeated selection, changed snapshots, two addresses for one contact, and deleting multiple rows without shifting the wrong index. The full four Swift blocks also compile together for iOS 18 with Xcode 27.0 and Swift 6.4, under both normal and MainActor default isolation.

Compilation cannot exercise a system permission sheet. Before shipping a Contacts feature, run it with undetermined, denied, limited, and full authorization. Try a contact with no email, one with several, cancellation, and picking the same address twice. For the ongoing-access variant, revoke a grant in Settings and confirm the app responds appropriately.

Verified September 30, 2026: the exact published snippets compile, and the shortlist’s value-model checks pass. The system picker and access-button interactions have not been automated or device-tested as part of this article. The APIs’ permission contracts above come from Apple’s documentation and the installed SDK headers.