Add a player
/whitelist add SteveSteve is on the list and can join once the whitelist is on.

/whitelist turns the server whitelist on or off and manages who is on it. When it is on, only listed players and operators can connect. It is a dedicated server command, run from the console or by an operator, and the usual way to keep a private server private.
/whitelist add <targets>/whitelist list/whitelist off/whitelist on/whitelist reload/whitelist remove <targets>// Only on a dedicated server: the command does not exist in single player or in a world opened to LAN.
| Argument | Expects | What it does |
|---|---|---|
| targets | Player name | Player name, UUID or selector for add and remove; an offline player works if you type the exact name. |
/whitelist add SteveSteve is on the list and can join once the whitelist is on.
/whitelist onFrom now on, only listed players and operators can connect.
/whitelist remove SteveSteve can no longer join while the whitelist is on.
/whitelist listPrints how many players are listed and their names.
/whitelist reloadReads whitelist.json again so changes made by hand take effect.
Fill in the fields, then copy the command.
Command generatorAdd your players first with /whitelist add Name, then switch the check on with /whitelist on. Players do not need to be online to be added: the server looks the account up by its exact name. The list is saved in whitelist.json. Anyone else who tries to join sees You are not white-listed on this server!. Operators can always join, listed or not.
add and remove change the list.list shows who is on it.on and off turn the check on or off without losing the list.reload reads whitelist.json again after you edited it by hand.Turning the whitelist on or removing someone does not disconnect players already online, unless the server enforces the whitelist (the enforce-whitelist setting). Otherwise, use /kick for them, or /ban for someone who must never come back. Check who is online with /list and give moderation rights to trusted players with /op.
✓ Checked in Java Edition 26.3 · updated 2 November 2026
No. Operators can always join the server, even when they are not on the list.
The server does not watch the file. Run /whitelist reload to apply your changes without a restart.
On a server, as an operator or from the server console: /whitelist add <targets>. It does not exist in single player.
Server operator, level 3. Only on a dedicated server: the command does not exist in single player or in a world opened to LAN.