Sign In with Google
Google Google login Google OAuth social login Google sign in Google authenticationSign Up for Google
Section titled “Sign Up for Google”- Sign up for Google Cloud if you don’t have one already.
Create a Google Cloud Project
Section titled “Create a Google Cloud Project”- Create a new Google Cloud project if you don’t already have a project you want to use.
Configure OAuth Consent Screen
Section titled “Configure OAuth Consent Screen”- Search for OAuth consent screen in the top search bar in the Google Cloud Console.
- Click on OAuth consent screen in the search results.
- Select User Type External and click CREATE.
Edit app registration
Section titled “Edit app registration”OAuth Consent Screen
Section titled “OAuth Consent Screen”- Fill in your App information.
- Click SAVE AND CONTINUE.
Scopes
Section titled “Scopes”- Click SAVE AND CONTINUE.
Test User
Section titled “Test User”- Click SAVE AND CONTINUE.
Summary
Section titled “Summary”- Click BACK TO DASHBOARD.
Create Credentials
Section titled “Create Credentials”- Click on Credentials under APIs & Services in the left menu.
- Click + CREATE CREDENTIALS and then OAuth client ID in the top menu.
- On the Create OAuth client ID page for Application Type select Web application.
- Under Authorized JavaScript origins, add your project’s redirect URL for the Google sign-in method in the following format:
https://<subdomain>.auth.<region>.nhost.run - Under Authorized redirect URIs add your OAuth Callback URL from Nhost.
- Click CREATE.
Configure Nhost
Section titled “Configure Nhost”- A modal appears with your Google Client ID and Client Secret.
- Copy and paste the Client ID and Client Secret from Google to your Nhost OAuth settings for Google. Make sure the OAuth provider is enabled in Nhost.
- Click the checkbox “I have pasted the redirect URI into Google”.
- Click Confirm settings.
Sign In Users
Section titled “Sign In Users”Once you’ve configured Google as an OAuth provider in Nhost, you can sign in users using the Google provider. See the OAuth Provider Sign-In Guide for detailed implementation instructions including the complete OAuth flow, error handling, and session management.