Create an Apple Developer Certificate with Xcode

Signing binaries compiled with Xcode requires a signing certificate. For local development, a free Apple Development certificate suffices; distributing software requires a paid Apple Developer Program membership.

Prerequisites

  • An Apple ID (free)
  • Xcode installed

Procedure

  1. Launch Xcode and open Settings (or Preferences on older versions).
  2. Go to Accounts.
  3. Click + to add a new account and sign in with the desired Apple ID.
  4. Select the account and click Manage Certificates.
  5. Click + and choose Apple Development from the pop-up menu.
  6. Click Done.

Xcode creates the certificate and stores the private key in your keychain. If using automatic signing (recommended), Xcode manages certificates automatically as needed.

Certificate types

TypePurpose
Apple DevelopmentRun apps on devices and use app services during development (Xcode 11+)
Apple DistributionDistribute apps for testing or submit to the App Store (Xcode 11+)
Developer ID ApplicationSign Mac apps distributed outside the Mac App Store
Developer ID InstallerSign Mac installer packages

Development certificates belong to individuals — you can create up to two iOS development certificates and two Mac development certificates. The computer name is appended to the certificate name in your developer account (e.g., Gita Kumar (Work Mac)).

Local vs. distributed signing

Binaries signed with a free Apple Development certificate work on the local system but fail signature checks on other machines. A paid Apple Developer Program membership is required to:

  • Distribute software on macOS via Developer ID signing
  • Submit apps to the App Store
  • Use notarization for Gatekeeper approval

Sources

Related: fuzzing-swift, get-ssl-certificate