> For the complete documentation index, see [llms.txt](https://lodestone-technologies.gitbook.io/knowledgebase/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://lodestone-technologies.gitbook.io/knowledgebase/minecraft-java/add-a-player-to-the-whitelist.md).

# Add a player to the whitelist

Whitelisting is a feature that allows you to limit the players who can access your server, increasing its security. When enabled, only whitelisted players can join your server.

{% hint style="info" %}
This guide only works on Java Edition. We have a [separate guide](/knowledgebase/add-a-player-to-the-allowlist.md) for Bedrock Edition.
{% endhint %}

## Using the server console

Head over to the [Game Panel](https://game.lodestone.host) and select "Console" on the sidebar menu.

<figure><img src="/files/x0D2oV4Pq2M9nLIMvZE9" alt=""><figcaption></figcaption></figure>

Make sure your server is online. You can now type "whitelist add \<username>" in the console. Make sure you replace "username" with the username of the player you wish to whitelist.

<figure><img src="/files/3BHd0aZkVJ7d47mumMtX" alt=""><figcaption></figcaption></figure>

You can use "whitelist remove \<username>" to unwhitelist the player. You can also use "whitelist list" to list all currently whitelisted players.

Use "whitelist on" or "whitelist off" to enable/disable the whitelist.

## Through in-game commands

Alternatively, you can whitelist players in-game. You'll [need to be an operator](/knowledgebase/minecraft-java/make-a-player-an-operator.md) for this to work.

Use the command "/whitelist add \<username>" in the server chat. Make sure you replace "username" with the username of the player you wish to whitelist.

<figure><img src="/files/wcnigbOQCwyZ9Dsb9kIr" alt=""><figcaption></figcaption></figure>

You can use "/whitelist remove \<username>" to unwhitelist the player. You can also use "whitelist list" to list all currently whitelisted players.

Use "/whitelist on" or "/whitelist off" to enable/disable the whitelist.


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://lodestone-technologies.gitbook.io/knowledgebase/minecraft-java/add-a-player-to-the-whitelist.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
