Deploy iOS Issue “Missing private key”

Ignasius
2 min readJan 15, 2021

One day, I assigned the task to update the iOS app to the App Store.
After I joined the apple developer group, I tried to publish via XCode, and there is the error

Xcode Publish Missing Private Key

To fix this error, open the apple developer page here, then go to Overview -> Certificates, Identifiers & Profiles.

On the Certificates, Click the + (Add Button), then select the Apple Distribution

Certificates, Identifiers & Profiles

Next, if you don’t already have CSR, you can create it, The step by step can be accessed by clicking on Learn More

Browse CSR

Then, click on the Continue Button, if successful, you will have this page

Download Certificate

After downloading, you will have a .cer file, now, double-clicking it to install into Keychain Access.

Now, it’s time to create a Provisioning Profile for Distribution

On the Apple Developer page, click on the Profiles, then + (Add Button ), then select the App Store

Provisioning Profile

Then select the App ID you want to deploy/publish.

Select the App ID

then select the certificates you created on the first step.

Click on Continue

Then click on Generate.

Click on Download.

Everything is complete. If in Xcode, you select Automatically Managed.

After that, you can deploy/publish/update the app into App Store.

--

--