Block entity format

Not to be confused with Entity format.
This feature is exclusive to Java Edition.
 

A block entity is used to store information about a block that can't be stored in the block's block states. It is stored inside the chunk data and structure files.

Block Entities
Block Entity ID Associated Block
banner Banner
barrel Barrel
beacon Beacon
bed Bed
beehive Bee nest/beehive
bell Bell
blast_furnace Blast Furnace
brewing_stand Brewing Stand
brushable_block Suspicious Block
calibrated_sculk_sensor Calibrated Sculk Sensor
campfire Campfire
chest Chest
chiseled_bookshelf Chiseled Bookshelf
comparator Redstone Comparator
command_block Command Block
conduit Conduit
crafter Crafter
creaking_heart Creaking Heart
daylight_detector Daylight Detector
decorated_pot Decorated Pot
dispenser Dispenser
dropper Dropper
enchanting_table Enchanting Table
ender_chest Ender Chest
end_gateway End Gateway
end_portal End Portal
furnace Furnace
hanging_sign Hanging Sign
hopper Hopper
jigsaw Jigsaw Block
jukebox Jukebox
lectern Lectern
mob_spawner Monster Spawner
piston Moving Piston
shulker_box Shulker Box
sign Sign
skull Mob head
sculk_catalyst Sculk Catalyst
sculk_sensor Sculk Sensor
sculk_shrieker Sculk Shrieker
smoker Smoker
soul_campfire Soul Campfire
structure_block Structure Block
trapped_chest Trapped Chest
trial_spawner Trial Spawner
vault Vault

NBT format

Block entities are stored using NBT, using the following format:

  • [NBT Compound / JSON Object]: A block entity
    • [String] id: Block entity ID
    • [Boolean] keepPacked: 1 or 0 (true/false) - If true, this is an invalid block entity, and this block is not immediately placed when a loaded chunk is loaded. If false, this is a normal block entity that can be immediately placed.
    • [Int] x: X coordinate of the block entity.
    • [Int] y: Y coordinate of the block entity.
    • [Int] z: Z coordinate of the block entity.
    • [NBT Compound / JSON Object] components: Optional map of components.
    • Additional fields depending on the block entity type ([String] id), see Block entity format § Types

Types

History

This section of the article is empty.
 
You can help by expanding it.

Navigation