Version:
Popular examples
Map
Geo objects
Balloon and hint
Controls
Hotspots
Regions
Clustering
GeoQuery
Behaviors and events
Search on a map
Traffic
User's location
Routing
YMapsML
GeoXML
ObjectManager
Modular system
Panoramas
External modules

Direct geocoding

Save as filesEdit on JSFiddle

The API can determine the coordinates of an object by its name (forward geocoding) and the name of an object by its coordinates (reverse geocoding).

Both types of geocoding are performed using the geocode function. The result returned by this function can be immediately placed on the map.

This example uses forward geocoding: to mark Nizhny Novgorod on the map, we determine the coordinates of its center, and then add a placemark with the found coordinates to the map.

The example shows how to work with data returned by the geocoder: how to add it to the map or, for example, how to extract the necessary information about an object.