Direct answer
Use /whitelist on, then /whitelist add PlayerName to restrict who can join a Java server. The console runs the same commands without /.
Recommended procedure
- Enter
/whitelist onto enable the allowlist. - Run
/whitelist add PlayerNamefor every trusted player. - Run
/whitelist listto inspect entries. - Use
/whitelist remove PlayerNameto revoke access. - If you edit the allowlist file outside Minecraft, follow your software’s documented reload procedure; prefer commands for normal changes.
Why this matters
Whitelisting is an access control, not a replacement for online authentication, secure operator accounts, or a proxy firewall. A wrongly configured proxy can bypass your intended backend access policy.
How to verify the result
Check /whitelist list, then attempt connection using a test account that is not listed. Check hosting-panel/proxy configurations if the allowlist is not enforced.
Version and compatibility notes
Commands shown are for Java dedicated servers. Some plugins replace or extend the allowlist; confirm which system handles joins before editing external files.
Official references
Related guides
Help us improve this article
Tell us what is missing, unclear, outdated, or incorrect. You can also suggest something we should add.