{{Infobox command
|name=kick
|oplevel=
* 3 {{only|java|short=1}}
* 1 {{only|bedrock|short=1}}
|others=No [[command blocks]]{{only|java|short=1}}
}}

Kicks a [[player]] off the [[server]], and displays an optional reason to it.

The player in a single player world or the host of a world cannot be kicked.

==Syntax==

* '''Java Edition'''
: <code>kick <targets> [<reason>]</code>

* '''Bedrock Edition'''
: <code>kick <name: target> [reason: message]</code>

== Arguments ==
{{argument|targets|entity|name: target|CommandSelector<Player>}}
: Specifies the player(s) to be kicked. Only 1 player to be kicked{{only|be}}.
: {{arg desc|je=entity|amount=multiple|type=players|be=player}}
: {{IN|bedrock}}, it can also be an XUID (Xbox UID) of a player.

{{argument|reason|message|reason: message|CommandMessage}}
: Message to display to the kicked player. {{IN|java}}, if unspecified, defaults to <code>Kicked by an operator</code>.
: {{arg desc|je=message|be=CommandMessage}}

==Result==

{{Result table}}
{{Result table|The command is incomplete, or any argument is not specified correctly.|unparseable|unparseable}}
{{Result table|<code>name: target</code> is a target selector that is not in [[Target selectors#Player type and single type|player type]].|N/A|fail}}
{{Result table|<code><targets></code> or <code>player: target</code> fails to resolve to one or more online players.|fail}}
{{Result table|Only one player is selected, and the player is the host of the world.}}
{{Result table|succeed}}
{{Result table}}

== Output ==

{{Output table}}
{{Output table|edition=je|On fail|N/A|0|0}}
{{Output table|On success|N/A|1|the number of targeted players}}
{{Output table|edition=be|On fail|0}}
{{Output table|On success|1}}
{{Output table}}

== History ==
{{HistoryTable
|{{HistoryLine|java classic}}
|{{HistoryLine||0.0.16a|Added {{cmd|kick|link=none}}.}}
|{{HistoryLine|java indev}}
|{{HistoryLine||0.31|Removed all commands.}}
|{{HistoryLine|java alpha}}
|{{HistoryLine||v1.0.16|Re-added {{cmd|kick|link=none}}.}}
|{{HistoryLine|java}}
|{{HistoryLine||1.20.3|dev=23w40a|The {{cmd|kick|link=none}} no longer kicks the player in a single player world or the host in a LAN world.}}

|{{HistoryLine|bedrock}}
|{{HistoryLine||1.16.0|dev=beta 1.16.0.57|Added {{cmd|kick|link=none}}.}}
}}

== Navigation ==
{{Navbox commands}}

[[de:Befehl/kick]]
[[es:Comandos/kick]]
[[ja:コマンド/kick]]
[[pt:Comandos/kick]]
[[ru:Команды консоли/kick]]
[[th:คำสั่ง/kick]]
[[uk:Команди консолі/kick]]
[[zh:命令/kick]]
