![]() |
VOOZH | about |
/tellraw| Permission level required |
|
|---|---|
| Restrictions | None |
{
"title": "<code>/tellraw</code>",
"rows": [
{
"field": "\n* 2 β<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* 1 β<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 JSON message to players.
tellraw <targets> <message>tellraw <target: target> <raw json message: json>JE: <targets>: entity
BE: target: target: CommandSelector<Player>
JE: <message>: component
BE: raw json message: json: Json::Value
| Command | Trigger | Java Edition | Bedrock Edition |
|---|---|---|---|
| Any | The command is incomplete, or any argument is not specified correctly. | Unparseable | Unparseable |
raw json message: json is not a raw JSON text. | N/A | Failed | |
player: target is a target selector that is not in player type. | |||
<targets> or player: target fails to resolve to one or more online players. | Failed | ||
| Otherwise | Successful | ||
| 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 | 1 | N/A | N/A |
| Java Edition | Bedrock Edition | Preview | |
|---|---|---|---|
| To send the message "Hello" in chat: | /tellraw @a "Hello"
|
/tellraw @a {"rawtext":[{"text":"Hello"}]}
|
π Hello |
| To send the message "I am blue" colored blue in chat: | /tellraw @a {"text":"I am blue","color":"blue"}
|
/tellraw @a {"rawtext":[{"text":"Β§9I am blue"}]}
|
π I am blue (In blue) |
| To send the message "Hover me!" in chat, which displays the text "Hi!" when hovered over: | /tellraw @a {text:"Hover me!",hover_event:{action:show_text,value:"Hi!"}}
|
π Hover me! (Hovered: Hi!) | |
| To send the message-colored dark red in chat: | /tellraw @a {text:"Y0U G3T B4CK H3R3 N0W",color:dark_red}
|
/tellraw @a {"rawtext":[{"text":"Β§4Y0U G3T B4CK H3R3 N0W"}]}
|
π Y0U G3T B4CK H3R3 N0W (Dark red) |
| To send the message "Read the fine print." in italics in chat: | /tellraw @a {text:"Read the fine print.","italic":true}
|
||
| Use '\n' to insert a new line: | /tellraw @a {text:"Text1\nText2"}
|
/tellraw @a {"rawtext":[{"text":"Text1\nText2"}]}
|
π Text1 (newline) Text2 |
| Use '\uE100' to insert a hunger bar emoji: | /tellraw @a {"rawtext":[{"text":"Text1\uE100Text2"}]}
|
||
| Display a message in the Enchanting Table's glyphs: | /tellraw @a {text:"Hello World",font:alt}
|
π βα·κκπΉ β΄πΉβ·κβΈ | |
| Display a message in the illager runes: | /tellraw @a {"text":"Hello World","font":"illageralt"}
|
π Hello World (illager runes) | |
| Display a translated string: | /tellraw @p {"translate":"item.minecraft.diamond"}
|
/tellraw @s {"rawtext":[{"translate":"item.diamond.name"}]}
|
π Diamond |
Simulate the output of /say @p loves Minecraft!, run through a command block:
|
/tellraw @a {"translate":"chat.type.announcement","with":[{"text":"@"},[{"selector":"@p"},{"text":" loves Minecraft!"}]]}
|
| Java Edition | |||||||
|---|---|---|---|---|---|---|---|
| 1.7.2 | 13w37a | Added /tellraw. | |||||
| 1.21.5 | 25w02a | Text Components are now specified with SNBT instead of JSON. | |||||
| Upcoming Java Edition | |||||||
| 26.3 | snapshot1 | The nbt component in a raw chat message will only be resolved up to 64k times. | |||||
| Bedrock Edition | |||||||
|---|---|---|---|---|---|---|---|
| 1.9.0 | beta 1.9.0.0 | Added /tellraw. | |||||
/say β send a plain text message to all players/tell β send a plain private text message to specific players/tellraw Command" β Microsoft Learn, October 11, 2023.