Sign-in

Stay organized with collections Save and categorize content based on your preferences.

Play Games Services sign-in authenticates players with Play Games Services and provides Android gaming identities (player ID) for use in cross-device play. Sign-in supports the Saved Games service, but you can also use player ID as a key for your own cloud save service.

SDK version

This topic is for the Play Games Services v2 SDK. For information on the previous SDK, see the Play Games Services v1 documentation.

The Play Games Services v2 SDK provides the following sign-in improvements over v1:

  • Improvements for users:
    • After selecting a default account, users are signed-in without needing to interact with a prompt.
  • Improvements for developers:
    • Client code no longer needs to handle the sign-in or sign-out flow, as login is automatically triggered when the game starts, and account management is handled in the OS settings.

Login request quota

There is a daily quota for login requests with Play Games Services. For more information, see Managing your daily quota.

Multiple sign-in services

Play Games Services provides a gaming identity for Android players, but it doesn't need to be the only identity connected to your users. You can sign in players using Play Games Services, a social network ID, and your own in-game ID system all at the same time.

Automatic sign-in

When a player launches a game with automatic sign-in enabled, they are signed into the game without interacting with the sign-in prompt. Players can enable automatic sign-in in the Google Play Games app, or in the initial sign-in prompt displayed in your game.

Automatic sign-in prompt

Player ID

A player ID is an identifier for a Play Games Services player account. Your game can retrieve a player ID for any player that signs into your game using Play Games Services sign-in. Your game client, backend game servers, and cloud-save service can use the ID to securely access player data from Play Games Services.

A player ID is consistent for a user when they play your game on multiple devices. However, it is not always consistent between games.

OAuth Scopes

Play Games Services relies on the OAuth system to allow players to give your game access to their account. Play Games Services has a unique scope for games (games-lite) and relies on another scope (drive.app_data) if your game uses the saved games feature. The saved games feature gives access to the user's Google Drive account, which is where the game data is stored.

When using the Play Games Services v2 SDK, you cannot request extra OAuth scopes. If you need extra OAuth scopes, we recommend using the Google Sign-In SDK with Play Games Services.

Game client integration

When integrating sign-in into your game project, we recommend the following user flow:

  1. During the startup sequence of your game, automatic sign-in launches and attempts to login the user or create a new account.

  2. If automatic sign-in does not work or the user declines, then show a manual sign-in button in case the user would like to login later.

For information about integrating sign-in in your game project, see the get started guide for your project type:

Game server integration

After a player signs into your game using the Sign-in services, your backend game server can communicate directly with Play Games Services servers to access a player's ID, profile, friends list, and other Play Games Services data. This requires a server authorization code that is provided by the Play Games Services SDK. Your server can use the authorization code along with the Play Games Services REST API to securely communicate with Play Games Services servers.

For more information, see Server-side access to Play Games Services.