How /tellraw Works
The /tellraw command sends a JSON text component to one or more players. Components can be plain text, a live selector (shows the current matching player), a scoreboard value, a keybind name, a translated string, or an NBT value — each with its own colors, formats, click event, and hover event.
Using the Command in Three Places
- Chat box — paste and press Enter. The chat input accepts about 256 characters; the length meter under the output tells you when a message is too long.
- Command block — paste into the block's command field for messages up to ~32,500 characters. Power it with a button, pressure plate, or redstone clock.
- Function file — save the command line in a datapack
.mcfunctionfile for reusable, versionable messages (welcome texts, menus, rules).
Component Type Reference
text— plain text with styles. Use the ⏎ button for a line break.selector— displays the name of whatever matches the selector right now.score— displays a scoreboard value, e.g. a player's kill count.keybind— shows the player's own key binding, e.g.key.jump.translate— localized message with optionalwitharguments.nbt— reads a value from a block, entity, or storage.- Hex colors — beyond the 16 named colors, any
#rrggbbvalue works on Java 1.16+. - Hover events — show_text (tooltip), show_item (item card, 1.16+), show_entity (entity card, 1.16+).
- insertion — text inserted when a player shift-clicks the component in chat.
Need exact IDs for items, entities, or score objectives? Browse the Minecraft Item ID List or the entity ID list.