<!--
{
  "availability" : [
    "iOS: 4.1.0 - 8.0.0",
    "iPadOS: 4.1.0 - 8.0.0",
    "macCatalyst: 13.1.0 - 13.1.0",
    "macOS: 10.8.0 - 10.10.0",
    "visionOS: 1.0.0 - 1.0.0",
    "watchOS: 2.0.0 - 2.0.0"
  ],
  "documentType" : "symbol",
  "framework" : "GameKit",
  "identifier" : "/documentation/GameKit/GKLeaderboard/init(playerIDs:)",
  "metadataVersion" : "0.1.0",
  "role" : "Initializer",
  "symbol" : {
    "kind" : "Initializer",
    "modules" : [
      "GameKit"
    ],
    "preciseIdentifier" : "c:objc(cs)GKLeaderboard(im)initWithPlayerIDs:"
  },
  "title" : "init(playerIDs:)"
}
-->

# init(playerIDs:)

Initializes a leaderboard request to retrieve the scores of a specific group of players.

```
init?(playerIDs: [String]?)
```

## Parameters

`playerIDs`

An array of `NSString` objects that holds the player identifier strings of the players to retrieve.

## Return Value

An initialized leaderboard request.

## Discussion

A leaderboard object that you initialize with this method ignores the [`playerScope`](/documentation/GameKit/GKLeaderboard/playerScope-swift.property) and [`range`](/documentation/GameKit/GKLeaderboard/range) properties. Instead, it retrieves scores for the specific list of players whose identifiers are in the `playerIDs` parameter.

---

Copyright &copy; 2026 Apple Inc. All rights reserved. | [Terms of Use](https://www.apple.com/legal/internet-services/terms/site.html) | [Privacy Policy](https://www.apple.com/privacy/privacy-policy)