Minecraft Wiki
Advertisement
locate
Permission level
required

2‌[JE only]
1‌[BE only]

Restrictions

Cheat only‌[BE only]

Displays the coordinates for the closest configured structure feature and biomes of a given type in the chat for the player who executed the command.

In Java Edition, it can also display points of interest.

Syntax[]

  • Java Edition
/locate structure <structure>
/locate biome <biome>
/locate poi <poi>
  • Bedrock Edition
/locate <feature: Feature>[until BE 1.19.10]
/locate structure <structure:Structure>[upcoming: BE 1.19.10]
/locate biome <biome:Biome>[upcoming: BE 1.19.10]

Arguments[]

JE (case-sensitive): <biome>

Specifies the biome to locate. Also supports biome tags.

JE (case-sensitive): <ConfiguredFeature>
BE: feature: Feature

Specifies the configured structure feature to locate. Must be one of the following:
Feature name Java Edition Bedrock Edition Dimension
Ancient city ancient_city ancientcity Overworld
Bastion remnant bastion_remnant bastionremnant The Nether
Buried treasure buried_treasure buriedtreasure Overworld
End city end_city endcity The End
Fortress fortress fortress The Nether
Woodland mansion mansion mansion Overworld
Mineshaft mineshaft
mineshaft_mesa
mineshaft Overworld
Monument monument monument Overworld
Nether fossil nether_fossil The Nether
Ocean ruins ocean_ruin_cold
ocean_ruin_warm
ruins Overworld
Pillager outpost pillager_outpost pillageroutpost Overworld
Ruined portal ruined_portal
ruined_portal_desert
ruined_portal_jungle
ruined_portal_mountain
ruined_portal_nether
ruined_portal_ocean
ruined_portal_swamp
ruinedportal Overworld, The Nether
Shipwreck shipwreck
shipwreck_beached
shipwreck Overworld
Stronghold stronghold stronghold Overworld
Desert pyramid desert_pyramid temple Overworld
Igloo igloo
Jungle pyramid jungle_pyramid
Swamp hut swamp_hut
Village village_desert
village_plains
village_savanna
village_snowy
village_taiga
village Overworld
In Java Edition, this argument also supports configured structure feature tag, as following:
Tag Structure(s)
#dolphin_located Underwater ruins
Shipwreck
#eye_of_ender_located Stronghold
#mineshaft Mineshaft
#ocean_ruin Underwater ruins
#on_ocean_explorer_maps Ocean monument

#on_treasure_maps

Buried treasure
#on_woodland_explorer_maps Woodland mansion
#ruined_portal Ruined Portal
#shipwreck Shipwreck
#village Village

JE (case-sensitive): <poi>

Specifies the point of interest to locate. Must be one of the following:
Point of Interest ID
Blast Furnace armorer
Bee nest bee_nest
Beehive beehive
Smoker butcher
Cartography Table cartographer
Brewing Stand cleric
Composter farmer
Barrel fisherman
Fletching Table fletcher
Bed home
Cauldron leatherworker
Lectern librarian
Lightning Rod lightning_rod
Lodestone lodestone
Stonecutter mason
Bell meeting
Nether Portal nether_portal
Loom shepherd
Smithing Table toolsmith
Grindstone weaponsmith
This argument also supports point of interest type tag, as following:
Tag Point of Interests
#acquirable_job_site armorer

butcher

cartographer

cleric

farmer

fisherman

fletcher

leatherworker

librarian

mason

shepherd

toolsmith

weaponsmith

#bee_home bee_nest

beehive

#village #acquirable_job_sitehome

meeting

Note[]

The vertical coordinate of the structure is ignored when finding.

In Java Edition, 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.[1]

If successful, the following message is sent to chat: "The nearest <structure_type> is at [<x> ~ <z>] (<distance> blocks away)", in which <distance> is the horizontal distance between the executor and the structure feature. In Java Edition, the coordinates can be clicked, which can put the command /tp @s <x> ~ <z> in the chat box. The command can then be executed, and the player is sent to those coordinates.

Result[]

CommandTriggerJava EditionBedrock Edition
anythe arguments are not specified correctly Unparseable Failed
the requested feature doesn't generate in this dimension Failed
unable to locate the requested feature within a square of 201×201 chunks[needs testing in Bedrock Edition]
On successDisplays the coordinates for the closest structure of the given type in the chat

Output[]

CommandEditionSituationSuccess Count/execute store success .../execute store result ...
anyJava EditionOn fail000
On success11horizontal distance between the executor and the structure feature
Bedrock EditionOn fail0N/AN/A
On success1N/AN/A

Examples[]

  • To obtain the coordinates of the nearest woodland mansion: /locate structure mansion[Java Edition only][upcoming: BE 1.19.10]//locate mansion[Bedrock Edition only][until BE 1.19.10]
  • To obtain the coordinates of the nearest village of any kind: /locate structure #village[Java Edition only][upcoming: BE 1.19.10]//locate village[Bedrock Edition only][until BE 1.19.10]
  • To obtain the coordinates of the nearest windswept hills biome: /locate biome windswept_hills[Java Edition only][upcoming: BE 1.19.10]
  • To obtain the coordinates of the nearest point of interest used by villagers: /locate poi #village[Java Edition only]

History[]

Gear (item).gif
This section is a work in progress. 
Please help in the expansion or creation of this article by expanding or improving it. The talk page may contain suggestions.
Java Edition
1.1116w39aAdded /locate.
1.1318w06a/locate now accepts different structure names for all structures previously grouped under Temple: Desert_Pyramid, Igloo, Jungle_Pyramid, and Swamp_Hut.
18w08aAdded a clickable teleport link to the /locate command output.
1.1620w11aNether fossils can now be located.
20w21aStructure names are now specified as lowercase.
1.18.222w03a/locate now uses a namespace ID parameter instead of hard coded values.
Pre-release 1/locate now support tags, using # prefix to distinguish from normal IDs.
The parameter is now a configured structure rather than a structure type.
1.1922w19a/locatebiome has been merged with /locate.
Added the ability to locate points of interest.
Pocket Edition
1.0.0alpha 0.17.0.1Added /locate.
alpha 0.17.0.2Removed /locate.
alpha 1.0.0.0Re-added /locate. Works only for strongholds.
1.1.0alpha 1.1.0.0/locate can now find other structures.
Upcoming Bedrock Edition
1.19.10beta 1.19.10.23/locate can now find biomes.

References[]

Advertisement