Skip to main content
Nudgra uses Google OAuth for dashboard sign-in. Create one web application credential in the Google Cloud Console, then set the redirect URI that matches your distribution.

Create OAuth credentials

1

Open the Google Cloud Console

Create or select a Google Cloud project.
2

Create OAuth credentials

Create credentials for a web application.
3

Set the authorized origin and redirect URI

Use the values for your distribution below.
4

Copy the client ID and secret

Store the values in your local and production environments.
If Google asks for an authorized domain, use the root domain. For example, use example.com when your app is on https://nudgra.example.com.

Local values

Authorized JavaScript origin:
http://localhost:3000

Authorized redirect URI:
http://localhost:3000/api/auth/callback/google
Put the client ID and secret in .env:
GOOGLE_CLIENT_ID=your-google-client-id
GOOGLE_CLIENT_SECRET=your-google-client-secret

Production values

Authorized JavaScript origin:
https://your-domain.com

Authorized redirect URI:
https://your-domain.com/api/auth/callback/google
Put the client ID and secret in .env:
GOOGLE_CLIENT_ID=your-google-client-id
GOOGLE_CLIENT_SECRET=your-google-client-secret
Restart after changing .env:
docker compose up -d --build
For Nudgra Cloud, the Google OAuth redirect URI uses the Convex site URL. Do not use https://your-app-domain.com/api/auth/callback/google.