Skip to main content
Version: 5.11.6

Set up Google Cloud Platform for iOS

To use Google Sign-in with iOS, a client ID for iOS must exist in your Google Cloud Platform (GCP) project.
If you already have a GCP project that you created for Google Sign-in for Android, you can use that project to start with the [Create a ClientID for iOS authentication] (#3- create-client-id-for-ios) topic.

1. Create a project on Google Cloud Platform

  • 1) Google Cloud Platform > Select Projects > Create New Project

  • 2) Enter a project name of your choice and click Create.

  • 3) After selecting the project, click APIs and services > OAuth consent screen in the sidebar.

  • 4) Click User Type as External.

  • 5) Enter only the required app name, user support email, and developer contact information, then click Save and continue.

  • 6) In the Scope field, click Save and continue without adding or editing any information.

  • 7) Add an account to test the Sign in with Google feature.

2. Get information from App Store Connect

To use the Sign in with Google feature on iOS, you need to create a total of one Client ID as follows.

  • iOS Client ID for iOS authentication

To create this Client ID, you need the following information, which can be obtained from the AppStoreConnect console

  • Bundle ID registered in App Store Connect
  • Apple ID registered with App Store Connect
  • Team ID registered in App Store Connect

2-1. Get Bundle ID

Go to App Store Connect > the app > General information > App information > Copy Bundle ID.

2-2. Get Apple ID

App Store Connect > App > General information > App information > Copy Apple ID.

2-3. Get your Team ID

At the top of App Store Connect, go to Users & Access > Select Admin account > People > Copy Team ID.

3. Create a Client ID for iOS

1) Click Create user credentials - OAuth Client ID.

2) Select the application type as iOS and enter the information copied from the above items.

3) Click Create.

4. Copy the iOS Client to use within the SDK

4-1. Copy the client ID

Copy the Client ID of the created iOS client.
This value will be used as the iOSClientId argument value of BackendFederation.iOS.GoogleLogin() in the iOS Google Login code.

4-2. Copy the iOS URL schema

Copy the iOS URL schema of the created iOS client. This value will be used as an argument to Info > URL Types > URL Schemes in the XCode Settings .xcworkspace that is created after building the Unity project.

Translated with DeepL.com (free version)