> For the complete documentation index, see [llms.txt](https://realisticnode.gitbook.io/rnsetups/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://realisticnode.gitbook.io/rnsetups/rnpsmenu/guides/bans.md).

# Region bans

Keep players out of a region for a while or forever, or send a visitor out right now.

Owners (and [operators](/rnsetups/rnpsmenu/guides/players.md#operators) with the Bans right) can ban players from their regions in **Region menu > Bans**.

<figure><img src="https://i.imgur.com/lKA9J4F.png" alt="The bans of a region, with the time left and the reason"><figcaption><p>The bans of a region, with the time left and the reason</p></figcaption></figure>

<figure><img src="https://i.imgur.com/ebn0sBL.png" alt="Choosing how long the ban lasts"><figcaption><p>Choosing how long the ban lasts</p></figcaption></figure>

<figure><img src="https://i.imgur.com/FQUyExy.png" alt="A banned player is stopped at the border"><figcaption><p>A banned player is stopped at the border</p></figcaption></figure>

1. **Ban a player**: pick an online player or type a name.
2. Choose how long: the times of `bans.durations` in `config.yml` (default 1 hour, 1 day, 7 days and forever; up to 7 times are offered).
3. Type a reason, or click **No reason**.

A banned player:

* can't walk, fly, ride or swim into the region;
* can't teleport into it (commands, ender pearls, chorus fruit, other plugins);
* is sent out at once if they are inside, when they join inside it, and when they respawn inside it;
* sees the reason and the time left.

Members, owners and tenants can't be banned (remove them first). Staff with `rnpsmenu.bypass.ban` (operators have it) can't be banned either, so they can always check a region: they are not in the list, and banning them by name is refused.

Bans end by themselves. Click a head in the bans menu to lift a ban earlier. When a region is removed its bans are removed too.

## Expel a visitor

**Bans > Expel a visitor** lists the visitors who are inside the region right now. Click one to send them out at once (to the place set by `kick-to`, like a ban). They can't come back for `bans.expel-seconds` (default 60 seconds).

* It is for "out, now" (a griefer, someone who won't leave): it is **not saved** and **not listed** as a ban.
* Needs `rnpsmenu.ban`, like bans.
* Members, owners and tenants can't be expelled, and neither can staff with `rnpsmenu.bypass.ban`.

## Settings

```yaml
bans:
  enabled: true
  durations: [60, 1440, 10080, 0]   # minutes, 0 = forever
  max-per-region: 100
  kick-to: EDGE                    # EDGE: just outside the region, SPAWN: world spawn
  message-cooldown-seconds: 3
  expel-seconds: 60                # 0 = an expelled player can come back at once
```

`kick-to` sets where a banned or expelled player goes: `EDGE` puts them just outside the region and `SPAWN` sends them to the world spawn. With `expel-seconds: 0` an expelled player can come back at once, and `enabled: false` turns off bans and expelling.

Bans use WorldGuard's own movement checks, so they add no work on every step of every player.
