Commands/msg
Minecraft Wiki article. Categories: Commands
📌 Mirrored from Minecraft Wiki
This article is reproduced from Commands/msg on the Minecraft Wiki. Mirrored from revision 3662684. It is licensed CC BY-NC-SA 3.0 by the Minecraft Wiki contributors — not under the Codex’s CC BY-SA 4.0, and it may not be used commercially. Edits belong upstream, not here.
On this page
/msg{
"title": "<code>/msg</code>",
"rows": [
{
"field": "\n* <!-- Command --><code ><span>/tell</span></code><!-- /Command -->\n* <!-- Command --><code ><span>/w</span></code><!-- /Command -->",
"label": "Aliases"
},
{
"field": "\n* 0 <sup class=\" nowrap Inline-Template \" title=\"\">[<i><span title=\"This statement only applies to Java Edition\">(link to Java Edition article, displayed as JE) only</span></i>]</sup>\n* 2 <sup class=\" nowrap Inline-Template \" title=\"\">[<i><span title=\"This statement only applies to Bedrock Edition\">(link to Bedrock Edition article, displayed as BE) only</span></i>]</sup>",
"label": "(link to Permission level article, displayed as Permission level<br>required)"
},
{
"field": "None",
"label": "(link to Commands#Restrictions article, displayed as Restrictions)"
}
],
"invimages": [],
"images": []
}
Sends a private message to one or more players.
Syntax
- Java Edition
/msg <targets> <message>
- Bedrock Edition
/msg <target: target> <message: message>
Arguments
JE: <targets>: entity
BE: target: target: CommandSelector<Player>
- Specifies the player(s) to send the message to.
- Must be a player name, a target selector or a UUID[Java Edition only]. And the target selector must[JE only]/should[BE only] be of player type. In Bedrock Edition, the target selector should be of player type.
JE: <message>: message
BE: message: message: CommandMessage
- Specifies the message to tell.
- It is a greedy phrase string argument (taking the rest of the command as the string argument). Can include spaces as well as target selectors. The game replaces entity selectors in the message with the list of selected entities' names, which is formatted as "name1 and name2" for two entities, or "name1, name2, ... and namen" for n entities. In Bedrock Edition,
@<player name>can be used to mention a player;@herecan be used to mention all players.
Result
| Command | Trigger | Java Edition | Bedrock Edition |
|---|---|---|---|
| Any | The command is incomplete, or any argument is not specified correctly. | Unparseable | Unparseable |
player: target is a target selector that is not of player type. | N/A | Failed | |
<targets> or player: target fails to resolve to one or more online players. | Failed | ||
| Otherwise | Successful | ||
Output
| Command | Edition | Situation | Success Count | /execute store success ... | /execute store result ... |
|---|---|---|---|---|---|
| Any | Java Edition | On fail | 0 | 0 | 0 |
| On success | 1 | 1 | the number of targeted players | ||
| Bedrock Edition | On fail | 0 | N/A | N/A | |
| On success | the number of targeted players | N/A | N/A |
Examples
- To privately tell Steve to start the game:
/tell Steve Start the game! - To say "Hi" to all online players:
/msg @a Hi - To whisper to Makena instructions to trap Zuri:
/w Makena Trap Zuri now!
History
Java Edition
| Java Edition Alpha | |||||||
|---|---|---|---|---|---|---|---|
| v1.0.16_02 | server 0.1.3 | Added /msg, /tell, and /w. | |||||
| Java Edition | |||||||
| 1.16.2 | Pre-release 2 | This command now displays the message to the sender even if /gamerule sendCommandFeedback is disabled.[2] | |||||
Bedrock Edition
| Pocket Edition Alpha | |||||||
|---|---|---|---|---|---|---|---|
| v0.16.0 | build 1 | Added /msg, /tell, and /w. | |||||
| Bedrock Edition | |||||||
| 1.21.120 | Due to MCPE-230568, /msg, /tell, and /w require operator permissions to use | ||||||
See also
/tellraw— send a JSON message to players.
External links
- "
/tellCommand" – Microsoft Learn, October 11, 2023.
References
- ↑ MCPE-230568 – Non-Operator Players can't use /whisper, /msg, or /tell. "insufficient permissions for selector expansion"
- ↑ MC-134084 – resolved as "Fixed".
Navigation
Sources
- Commands/msg — Minecraft Wiki, CC BY-NC-SA 3.0, revision 3662684.