Since Minecraft now has a lot of Mobs and NPCs you might be wondering how can you see their hitboxes. In Minecraft Java it’s actually pretty simple, just press key F3 and B on your keyboard at the same time. This will toggle hitboxes on and off for you.
Hitboxes look like straight lines around mobs and NPCs and can be used to determine entity position. Keep in mind hitboxes do not always match up with the exact shape of entities either, sometimes various body parts will stick out. This is especially important to recognize as even if players hit an entity with a weapon in an area they don’t have a hitbox, no damage will take place.
But there’s more! Minecraft hitboxes will also show an entity’s lines of sight. This can be seen by a large red rectangle that surrounds the entire head of entity. This is why players in Minecraft can’t sneak up on mobs, they are programmed to have the literal equivalent of having eyes on the back of their head. Players can still know which way an entity is facing by looking at the blue line that extends away from the eyes when using hitboxes.