Commands/locate

Displays the coordinates for the closest generated structure or biomes of a given type in the chat for the player who executed the command. , it can also display for the closest points of interest.
== Syntax ==
* Java Edition
:/locate structure <structure>
:/locate biome <biome>
:/locate poi <poi>
*Bedrock Edition
:/locate structure <structure: Structure> [useNewChunksOnly: Boolean]
:/locate biome <biome: Biome>
==Arguments==
 : 
: 
: Specifies the biome to locate. In Java Edition, this argument also supports biome tags.
:
 (case-sensitive): 
: 
:Specifies the structure to locate. See Generated structures#Data values.
:
: 
:Specifies if a structure of any type wants to be located in new chunks only (true) or not (false), and it's false by default.
:
 : 
:Specifies the point of interest to locate. 
: 
: The following are resource locations of POIs:
: 
Point of Interest	ID
Blast Furnace 	
Bee nest 	
Beehive 	
Smoker 	
Cartography Table	
Brewing Stand 	
Composter 	
Barrel 	
Fletching Table 	
Bed 	
Cauldron 	
Lectern 	
Lightning Rod 	
Lodestone 	
Stonecutter 	
Bell 	
Nether Portal 	
Loom 	
Smithing Table 	
Grindstone 	
:This argument also supports point of interest type tags, as following:
: 
Tag 	Includes
#acquirable_job_site	
 	
 	
==Note==
For , the vertical coordinate of structure is ignored when finding. , the horizonal search range is 201×201 chunks. Structures in the Anvil chunk region of the command's execution are prioritized over others due to a bug, meaning the found structure is not necessarily the closest.
For , the horizonal search resolution is 32 blocks, and vertical resolution is 64 blocks, which means biomes that are too narrow may not be found. The horizonal search range is 12801×12801 blocks .
, for , the search range is a ball with a radius of 256 blocks.
When locating structure or POI, if successful, the following message is sent to chat: "The nearest <requested thing(s)> is at [<x> ~ <z>] (<distance> blocks away)", in which <distance> is the horizontal distance from the executor. 
When locating biome, if successful, the following message is sent to chat: "The nearest <requested biome(s)> is at [<x> <y> <z>] (<distance> blocks away)", in which <distance> is the distance from the executor to the biome. 
, the coordinates in these messages can be clicked, which can put the command in the chat box. The command can then be executed, and the player is sent to those coordinates.
==Result==
==Output==
==Examples== 
* To obtain the coordinates of the nearest woodland mansion: 
* To obtain the coordinates of the nearest pillager outpost in new chunks only: 
*To obtain the coordinates of the nearest village of any kind: /
* To obtain the coordinates of the nearest desert biome: 
*To obtain the coordinates of the nearest point of interest used by villagers: 
==History==
==References==
de:Befehl/locate
ja:コマンド/locate
pt:Comandos/locate
ru:Команды консоли/locate
uk:Команди консолі/locate
zh:命令/locate