> ## Documentation Index
> Fetch the complete documentation index at: https://www.anything.com/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# Google Sign In

> Let users sign in to your app with their Google account

Let users sign in to your app with their Google accounts. They'll share their email, name, profile picture, and language settings.

<Warning>
  **Google Auth is not yet available for mobile apps.** We are working on this feature. Currently, Google Sign In only works for web apps published to custom domains.
</Warning>

You'll need to set up a few things in Google first, then add those settings to Anything.

## Before you start

Make sure you have:

<Check>
  An Anything project with [User Accounts](/apps/auth) turned on
</Check>

<Check>
  Your app running on a custom domain through [Anything's domain setup](/launch/domains)
</Check>

<Warning>
  Google Sign In needs a custom domain - you can't use the default `created.app` domains. You'll need:

  * A domain you own
  * [Anything Pro subscription](https://anything.com/pricing)
  * DNS records properly configured
</Warning>

## Overview

<CardGroup cols={2}>
  <Card title="Create Google Credentials" icon="key">
    Set up Google OAuth
  </Card>

  <Card title="Add to Anything" icon="plug">
    Add credentials to Anything
  </Card>

  <Card title="Add sign-in UI" icon="pencil">
    Customize the login button
  </Card>

  <Card title="Test flow" icon="check-circle">
    Make sure login works
  </Card>
</CardGroup>

## Google Cloud Setup

<Steps>
  <Step title="Access Google Cloud OAuth Clients">
    1. Go to [Google Cloud OAuth Clients](https://console.cloud.google.com/auth/clients)
    2. Sign in with your Google account

    <img src="https://mintcdn.com/create/Gl2O6oYpcGusVDs1/images/auth/google/1-gotoclients.png?fit=max&auto=format&n=Gl2O6oYpcGusVDs1&q=85&s=57aeea69a58bbd6b0b1b6465ff5e07ed" style={{ borderRadius: '0.5rem' }} width="3456" height="2078" data-path="images/auth/google/1-gotoclients.png" />
  </Step>

  <Step title="Select or Create Project">
    1. Click the project selector dropdown
    2. Choose to create a new project or select an existing one

    <img src="https://mintcdn.com/create/Gl2O6oYpcGusVDs1/images/auth/google/2-selectormakenewproject.png?fit=max&auto=format&n=Gl2O6oYpcGusVDs1&q=85&s=46482872baae2232a25fcf13ab85ecbd" style={{ borderRadius: '0.5rem' }} width="3456" height="1984" data-path="images/auth/google/2-selectormakenewproject.png" />
  </Step>

  <Step title="Configure New Project">
    1. If creating new: Enter a recognizable project name (internal use only)
    2. Choose whether to add it to an existing Organization or "No organization"
    3. Click "Create"

    <img src="https://mintcdn.com/create/Gl2O6oYpcGusVDs1/images/auth/google/3-nameprojectaddtoorg.png?fit=max&auto=format&n=Gl2O6oYpcGusVDs1&q=85&s=4ad785021e01d3f26f2066c2fc2a9b4f" style={{ borderRadius: '0.5rem' }} width="3456" height="2080" data-path="images/auth/google/3-nameprojectaddtoorg.png" />
  </Step>

  <Step title="Initialize Google Auth Platform">
    1. Once project is selected/created
    2. Click "Get Started" on the Google Auth Platform screen

    <img src="https://mintcdn.com/create/Gl2O6oYpcGusVDs1/images/auth/google/4-hitgetstartedfromproject.png?fit=max&auto=format&n=Gl2O6oYpcGusVDs1&q=85&s=8031197103c10c89b15a03dce7d42904" style={{ borderRadius: '0.5rem' }} width="3456" height="1986" data-path="images/auth/google/4-hitgetstartedfromproject.png" />
  </Step>

  <Step title="Configure App Information">
    1. Enter your App Name (this will be public-facing)
    2. Add a support email address (this will be public-facing)

    <img src="https://mintcdn.com/create/Gl2O6oYpcGusVDs1/images/auth/google/5-addappnamesupportemail.png?fit=max&auto=format&n=Gl2O6oYpcGusVDs1&q=85&s=8ad06238d1b272926390cecd1c669895" style={{ borderRadius: '0.5rem' }} width="3456" height="1982" data-path="images/auth/google/5-addappnamesupportemail.png" />
  </Step>

  <Step title="Select User Type">
    1. Choose your app's audience
    2. Select "External" unless this is an internal app for your Google Workspace organization

    <img src="https://mintcdn.com/create/Gl2O6oYpcGusVDs1/images/auth/google/6-decideaudience.png?fit=max&auto=format&n=Gl2O6oYpcGusVDs1&q=85&s=ddcf1715c4a360f30b0f0f502883cbcf" style={{ borderRadius: '0.5rem' }} width="3456" height="1982" data-path="images/auth/google/6-decideaudience.png" />
  </Step>

  <Step title="Add Contact Information">
    1. Enter developer contact email address
    2. This will be used by Google to contact you about your application

    <img src="https://mintcdn.com/create/Gl2O6oYpcGusVDs1/images/auth/google/7-addcontactinfo.png?fit=max&auto=format&n=Gl2O6oYpcGusVDs1&q=85&s=5ca820cb58b88c8788a6521800732410" style={{ borderRadius: '0.5rem' }} width="3456" height="1986" data-path="images/auth/google/7-addcontactinfo.png" />
  </Step>

  <Step title="Create OAuth Client">
    1. Navigate to credentials section
    2. Click "Create OAuth Client"

    <img src="https://mintcdn.com/create/Gl2O6oYpcGusVDs1/images/auth/google/8-createoauthclient.png?fit=max&auto=format&n=Gl2O6oYpcGusVDs1&q=85&s=220fc132cd7dd84334cf98603a9be9fb" style={{ borderRadius: '0.5rem' }} width="3456" height="1986" data-path="images/auth/google/8-createoauthclient.png" />
  </Step>

  <Step title="Configure OAuth Client">
    1. Select "Web Application" as the application type
    2. Name your client (e.g., "Production")

    <img src="https://mintcdn.com/create/Gl2O6oYpcGusVDs1/images/auth/google/9-webapplicationclientname.png?fit=max&auto=format&n=Gl2O6oYpcGusVDs1&q=85&s=cc5cce606c753aba499b7299cb581c29" style={{ borderRadius: '0.5rem' }} width="3456" height="1988" data-path="images/auth/google/9-webapplicationclientname.png" />
  </Step>

  <Step title="Configure Authorized Origin and Redirect URI">
    1. Add `https://www.your-custom-domain.com` as an Authorized JavaScript Origin (replace with your actual domain)
    2. Add `https://www.your-custom-domain.com/api/auth/callback/google` as an Authorized redirect URI

    <img src="https://mintcdn.com/create/Gl2O6oYpcGusVDs1/images/auth/google/10-authorizedorigin.png?fit=max&auto=format&n=Gl2O6oYpcGusVDs1&q=85&s=fdfab1473094c2135a51a0e68afa7115" style={{ borderRadius: '0.5rem' }} width="1104" height="1218" data-path="images/auth/google/10-authorizedorigin.png" />

    <Warning>
      Must include:

      * `https://` protocol prefix in both fields
      * `www` prefix in both fields
      * Exact domain used for the app in Anything's custom domain settings
      * Valid CNAME record for `www` subdomain configured in DNS ([see Domains guide](/launch/domains#connect-an-existing-domain))
    </Warning>
  </Step>

  <Step title="Copy Client ID">
    1. Create the OAuth Client
    2. Copy the generated Client ID
    3. Save it for adding to your Anything project later

    <img src="https://mintcdn.com/create/Gl2O6oYpcGusVDs1/images/auth/google/11-copyclientid.png?fit=max&auto=format&n=Gl2O6oYpcGusVDs1&q=85&s=7f720656c97d6fb747fc537ef15333fa" style={{ borderRadius: '0.5rem' }} width="3456" height="1984" data-path="images/auth/google/11-copyclientid.png" />
  </Step>

  <Step title="Copy Client Secret">
    1. Click the Edit button
    2. Copy the Client Secret
    3. Save it for adding to your Anything project later

    <img src="https://mintcdn.com/create/Gl2O6oYpcGusVDs1/images/auth/google/12-copyclientsecret.png?fit=max&auto=format&n=Gl2O6oYpcGusVDs1&q=85&s=1b7ce3b39a61d8838f1f770cecc1f4c5" style={{ borderRadius: '0.5rem' }} width="3456" height="1982" data-path="images/auth/google/12-copyclientsecret.png" />
  </Step>

  <Step title="Customize Branding (Optional)">
    1. Navigate to the Branding section
    2. Add your app domain, privacy policy, and terms
    3. These will appear on the Google Sign In page

    <img src="https://mintcdn.com/create/Gl2O6oYpcGusVDs1/images/auth/google/13-customizebranding.png?fit=max&auto=format&n=Gl2O6oYpcGusVDs1&q=85&s=0c6f4133c2db8feaa4f76e06c7ecd86c" style={{ borderRadius: '0.5rem' }} width="3456" height="1984" data-path="images/auth/google/13-customizebranding.png" />
  </Step>

  <Step title="Configure Additional Scopes (Optional)">
    1. If your app needs additional permissions
    2. Request additional scopes as needed

    <img src="https://mintcdn.com/create/Gl2O6oYpcGusVDs1/images/auth/google/14-optionaladdscopes.png?fit=max&auto=format&n=Gl2O6oYpcGusVDs1&q=85&s=530af51a1274c0ff5e091f923c1d8fad" style={{ borderRadius: '0.5rem' }} width="3456" height="2078" data-path="images/auth/google/14-optionaladdscopes.png" />
  </Step>

  <Step title="Submit for Verification (Later)">
    <Warning>
      Before going live, submit your app for verification in the Verification Center.
      This is required for external Google users to sign in to your app.
    </Warning>
  </Step>
</Steps>

## Add to Anything project

<Steps>
  <Step title="Enable User Accounts in your Anything project">
    You have two options:

    1. Prompt Anything with "Let users sign in"
    2. Enable User Accounts from the logo menu

    <Warning>
      User Accounts must be enabled before proceeding with Google Sign In setup
    </Warning>
  </Step>

  <Step title="Access Project Settings">
    1. Click the 3-dot menu at the top of the chat
    2. Select "Project Settings"

    <img src="https://mintcdn.com/create/Gl2O6oYpcGusVDs1/images/auth/google/15-3dotprojectsettings.png?fit=max&auto=format&n=Gl2O6oYpcGusVDs1&q=85&s=c5dde8c3aa220d5a2532b7af35a6dc04" style={{ borderRadius: '0.5rem' }} width="3456" height="1982" data-path="images/auth/google/15-3dotprojectsettings.png" />
  </Step>

  <Step title="Enable Google Sign In">
    1. Navigate to the Authentication section
    2. Find Google Sign In toggle
    3. Make sure it's turned on

    <img src="https://mintcdn.com/create/Gl2O6oYpcGusVDs1/images/auth/google/16-enablegooglesignin.png?fit=max&auto=format&n=Gl2O6oYpcGusVDs1&q=85&s=f46b4e0bc1df5af292bc70d580f3d82f" style={{ borderRadius: '0.5rem' }} width="3456" height="1984" data-path="images/auth/google/16-enablegooglesignin.png" />
  </Step>

  <Step title="Add Google Credentials">
    1. Paste in your Client ID from the previous section
    2. Paste in your Client Secret from the previous section
    3. Click Save to store your credentials

    <img src="https://mintcdn.com/create/Gl2O6oYpcGusVDs1/images/auth/google/17-pasteclientidsecret.png?fit=max&auto=format&n=Gl2O6oYpcGusVDs1&q=85&s=a35c32775ac91cc065c647ca22fbadf5" style={{ borderRadius: '0.5rem' }} width="3456" height="1986" data-path="images/auth/google/17-pasteclientidsecret.png" />
  </Step>

  <Step title="Add Sign In UI">
    1. Return to the chat
    2. Prompt Anything with something like "Add Google Sign In as an option"
    3. Anything will automatically update your sign-in pages with Google Sign In
    4. You can customize the UI further if you'd like.

    <img src="https://mintcdn.com/create/Gl2O6oYpcGusVDs1/images/auth/google/18-promptcreateaddsignin.png?fit=max&auto=format&n=Gl2O6oYpcGusVDs1&q=85&s=95a2ef8207da3c73bd9dc5f8a5bf693a" style={{ borderRadius: '0.5rem' }} width="3456" height="1986" data-path="images/auth/google/18-promptcreateaddsignin.png" />
  </Step>

  <Step title="Publish Your App">
    1. Click the Publish button
    2. Review your changes
    3. Publish to make the Google Sign In feature live
  </Step>

  <Step title="Test the Flow">
    1. Open your published app in an incognito window
    2. Navigate to the sign-in page
    3. Click the Google Sign In button
    4. Complete the Google authentication flow
    5. Verify you're successfully logged in to your app
    6. Check the user is logged in by looking at the [auth\_users table](/apps/databases) in your database

    <Warning>
      Always test the authentication flow in an incognito window to ensure it works for new users
    </Warning>
  </Step>
</Steps>

## Testing

1. Publish your changes
2. Open your app in a new incognito window
3. Go to the sign in page
4. Try signing in with Google
5. Check the [auth\_users table](/apps/databases) to see your new user

## Troubleshooting

<Accordion title="Can't see the Google button">
  * Check if User Accounts is turned on
  * Make sure Google Sign In is enabled in Project Settings
  * Try publishing your changes again
  * Clear your browser data and try in incognito mode
</Accordion>

<Accordion title="Getting 'Access Blocked: This app's request is not valid'">
  <img src="https://mintcdn.com/create/Gl2O6oYpcGusVDs1/images/auth/google/error-requestinvalid.png?fit=max&auto=format&n=Gl2O6oYpcGusVDs1&q=85&s=c551b5b3d7d5c2986292a679f62c353c" style={{ borderRadius: '0.5rem' }} width="720" height="375" data-path="images/auth/google/error-requestinvalid.png" />

  <img src="https://mintcdn.com/create/Gl2O6oYpcGusVDs1/images/auth/google/error-requestinvaliddetails.png?fit=max&auto=format&n=Gl2O6oYpcGusVDs1&q=85&s=bf37a887c3c0e27182f7904d10e6b739" style={{ borderRadius: '0.5rem' }} width="720" height="375" data-path="images/auth/google/error-requestinvaliddetails.png" />

  * Check that your Client ID and Client Secret are correctly pasted in Anything
  * Ensure your domain is added as an Authorized JavaScript Origin in Google Cloud
  * Verify your app is published and accessible at your custom domain

  <Tip>
    In Google Cloud, always use '[https://www.your-domain.com](https://www.your-domain.com)' not just 'your-domain.com'. Many login problems happen because people forget the 'https\://' protocol and 'www' prefix.
  </Tip>
</Accordion>

<Accordion title="Login not working">
  * Double check your domain is exactly the same in Anything and Google Cloud
  * Make sure your callback URL is right: `https://www.[your-domain].com/api/auth/callback/google`
  * Check if your Client ID and Secret are pasted correctly
  * Make sure your domain is set up in Google Cloud
  * Make sure your app is live at your custom domain
</Accordion>

<Accordion title="Seeing 'App not verified by Google'">
  * This is normal during testing
  * You can test with up to 100 users
  * For a live app, you'll need Google to verify it
  * Fill out all the info Google asks for
</Accordion>

<Accordion title="Users can't sign in after domain change">
  * Update the Authorized JavaScript Origins in Google Cloud
  * Update the Authorized redirect URIs in Google Cloud
  * Update your domain in the OAuth consent screen
  * Re-publish your app on the new domain
</Accordion>

## FAQ

<Accordion title="Can I use created.app domains?">
  No, Google Sign In needs your own domain. You'll need:

  * A domain you own
  * Anything Pro subscription
  * Properly configured DNS records
</Accordion>

<Accordion title="What user info do I get?">
  By default:

  * Email address
  * Name
  * Profile picture (if they have one)

  Additional information requires requesting extra scopes in Google Cloud Console.
</Accordion>

<Accordion title="Can I change how the login button looks?">
  Yes! Just:

  1. Go back to chat
  2. Tell Anything how you want it to look
  3. Anything will help style it while following Google's rules
</Accordion>

<Accordion title="Do I need Google to verify my app?">
  * For testing (up to 100 users): No
  * For a live app: Yes
  * Internal Google Workspace apps: No
</Accordion>

<Accordion title="How do I add more permissions/scopes?">
  1. Go to Google Cloud Console OAuth consent screen
  2. Add additional scopes in the "Scopes" section
  3. Provide justification for each scope
  4. Note: Additional scopes may require Google verification
</Accordion>

<Accordion title="Can I use Google Auth for internal tools and permissioning?">
  Yes! Configure your app as "Internal" in Google Cloud Console to unlock enterprise features:

  * **Skip verification** - No Google app review required
  * **Automatic user sync** - Users managed through your Google Workspace
  * **Built-in permissions** - Use Google Workspace groups and roles
  * **Enterprise SSO** - Seamless sign-in with existing credentials

  Perfect for internal dashboards, employee portals, and any app where you need to restrict access to your organization.
</Accordion>

## See Also

* [User Accounts](/apps/auth)
* [Customizing Login Pages](/apps/auth#customizing-auth-pages)
