- Add the following project variable to your
variables.gradle
file (usuallyandroid/build.gradle
):Runext { + rgcfaIncludeGoogle = true }
npx cap update
to update the native plugins and dependencies. - Specify your app's SHA-1 fingerprint from the Settings page of the Firebase console. Refer to Authenticating Your Client for details on how to get your app's SHA-1 fingerprint.
- Enable Google Sign-In in the Firebase console:
- Open the Auth section in the Firebase console.
- Open the Sign-in method tab and enable Google Sign In.
- Add the
RobingenzCapacitorFirebaseAuthentication/Google
pod to yourPodfile
(usuallyios/App/Podfile
):Runtarget 'App' do capacitor_pods # Add your Pods here + pod 'RobingenzCapacitorFirebaseAuthentication/Google', :path => '../../node_modules/@robingenz/capacitor-firebase-authentication' end
npx cap update
to update the native plugins and dependencies. - Add custom URL schemes to your Xcode project:
- Open your project configuration. Select your app from the TARGETS section, then select the Info tab, and expand the URL Types section.
- Click the + button, and add a URL scheme for your reversed client ID.
You find this value in your
GoogleService-Info.plist
configuration file. Look for theREVERSED_CLIENT_ID
key and paste the value of that key into the URL Schemes box on the configuration page. Leave the other fields blank.
- See Before you begin and follow the instructions to configure and enable sign-in with Google correctly.