Skip to main content

Display a player's ranking using the new Leaderboard service

Last updated on April 4, 2024


The AccelByte Gaming Services (AGS) Leaderboard service allows you to create a competitive atmosphere among players by displaying the leaderboard and providing information about player rankings.


  • Explain how to use the SDK to retrieve a leaderboard, or retrieve a specific player's ranking.
  • Provide an overview of how to display the leaderboard.
  • Explain how to display the leaderboard for all time and a specific time window.
  • To explain how to use leaderboards using AGS SDK.


  • Access to the AGS Admin Portal.
  • Access to the AGS SDK for Unreal or Unity.
  • Access to the AGS Leaderboard. View the API documentation for more information.
  • A leaderboard configuration you want to display. You can use the guide on new cycled leaderboards to create a leaderboard configuration.

Display the leaderboard rankings

To display the leaderboard rankings, you need to get the leaderboard data using the desired leaderboard code and time frame/cycle of the leaderboard. The total number of players that you want to display from the leaderboard also can be set based on your game's needs.

You can use the following function to get the leaderboard rankings:

Get leaderboard rankings

const FApiClientPtr ApiClient = FMultiRegistry::GetApiClient("Client1");

ApiClient->Leaderboard.GetRankingsV3(LeaderboardCode,Offset, Limit,
[&](const FAccelByteModelsLeaderboardRankingResultV3& Response)
// Handle response data here
[&](const int32 Code, const FString& Message)
// Handle error here

Display a specific player's ranking

You can display or highlight a specific player's ranking.

You can get a specific player's ranking using their user ID with the following function:

Get a specific player's ranking

const FApiClientPtr ApiClient = FMultiRegistry::GetApiClient("Client1");

THandler<FAccelByteModelsUserRankingDataV3>::CreateLambda([&](const FAccelByteModelsUserRankingDataV3& Response)
// Handle response data here

}), FErrorHandler::CreateLambda([&](const int32 Code, const FString& Message)
// Handle error here