Manage OAuth Clients

Your OAuth client is the credential which your application uses when making calls to Google OAuth 2.0 endpoint to receive an access token or ID token. After creating your OAuth client, you will receive a client ID and sometimes, a client secret.

Think of your client ID like your app's unique username when it needs to request an access token or ID token from Google's OAuth 2.0 endpoint. This ID helps Google identify your app and ensure that only authorized applications can access user data.

Client ID and Client Secret

Similar to how you would use a username and password to log to online services, many applications use a client ID paired with a client secret. The client secret adds an extra layer of security, acting like your app's password.

Applications are categorized as either public or private clients:

  • Private Clients: These apps, like web server applications, can securely store the client secret because they run on servers you control.
  • Public Clients: Native apps or JavaScript-based apps fall under this category. They cannot securely store secrets, as they reside on user devices and as such do not use client secrets. 

To create an OAuth 2.0 client ID in the console: 

  1. Navigate to the Google Auth Platform Clients page. 
    1. You will be prompted to create a project if you do not have one selected. 
    2. You will be prompted to register your application to use Google Auth if you are yet to do so. This is required before creating a client.   
  2. Click CREATE CLIENT
  3. Select the appropriate application type for your application and enter any additional information required. Application types are described in more detail in the following sections.
  4. Fill out the required information for the select client type and click the CREATE button to create the client.

Note : Your application’s client secret will only be shown after you create the client. Store this information in a secure place because it will not be visible or accessible again. If the client secret is lost, you will need to create a new one using the client secret rotation feature.

Application types

 

Delete OAuth Clients

To delete a client ID, go to the Clients page, check the box next to the ID you want to delete, and then click the DELETE button.

Before deleting a Client ID, ensure to check the ID is not in use by monitoring your traffic in the overview page.  

You can restore deleted clients within 30 days of the deletion. To restore a recently deleted client, navigate to the Deleted credentials page to find a list of clients you recently deleted and click the RESTORE button for the client you want to restore.  

Any client deleted over 30 days ago cannot be restored and is permanently deleted. 

Rotating your clients secrets

Client secrets or credentials should be treated with extreme care as described in the OAuth 2.0 policies, because they allow anyone who has them to use your app's identity to gain access to user information. With the client secret rotation feature, you can add a new secret to your OAuth client configuration, migrate to the new secret while the old secret is still usable, and disable the old secret afterwards. This is useful when the client secret has been inadvertently disclosed or leaked. This also ensures good security practices by occasionally rotating your secrets without causing downtime of your app. In addition, Google started to issue more secure client secrets recommended by RFC 6749 in 2021. While apps that were created earlier are able to continue using the old secrets, we recommend that you migrate to the new secret with this rotation feature. 

To rotate your client secret, please follow the following steps:

 

Was this helpful?

How can we improve it?
5663631007367802832
true
Search Help Center
true
true
true
true
true
95384
false
false
false
Search
Clear search
Close search
Main menu