Instance Method


Load all of the leaderboards for the current leaderboard set.


- (void)loadLeaderboardsWithCompletionHandler:(void (^)(NSArray<GKLeaderboard *> *leaderboards, NSError *error))completionHandler;



A block that is called when the categories have been retrieved from the server.

The block receives the following parameters:


An array of GKLeaderboard objects that provides the leaderboards for your game. If an error occurred, this value may be non-nil. In this case, the array holds whatever data Game Kit was able to download before the error occurred.


If an error occurred, this error object describes the error. If the operation completed successfully, the value is nil.


When this method is called, it creates a new background task to handle the request. The method then returns control to your game. Later, when the task is complete, Game Kit calls your completion handler. The completion handler is always called on the main thread.

See Also

Loading the Leaderboard Sets

- loadImageWithCompletionHandler:

Load the image associated with the leaderboard set.

+ loadLeaderboardSetsWithCompletionHandler:

Load all of the leaderboard sets for the current game.


Localized title for the leaderboard set.


The identifier for the leaderboard set.


Identifies the group that the leaderboard set belongs to.

Beta Software

This documentation contains preliminary information about an API or technology in development. This information is subject to change, and software implemented according to this documentation should be tested with final operating system software.

Learn more about using Apple's beta software