The information on this page may no longer be accurate. To see the latest, go to our new and improved documentation. You can also learn more about the future of documentation.
Collapse Sidebar




The MaxPlayers Players property determines the maximum amount of players that can be in this server.

While this property cannot be set through Scripts or LocalScripts in-game, it can be set from the place settings’ Access tab on the site.

You can change this value depending on the number of player’s you would like to limit in a single server. The number of players in a server affects the feel of your game and it’s performance.

Code Samples

PreferredPlayers Example

The script below prints a table displaying the Players/MaxPlayers, Players/PreferredPlayers, and the number of players currently on the server.

Maximum Preferred Current
Maximum number of players allowed in the server Preferred number of players in the server Number of players currently in the server