**European Economic Area (EEA) developers**

> [!NOTE]
> If your billing address is in the European Economic Area, effective on 8 July 2025, the [Google Maps Platform EEA Terms of Service](https://cloud.google.com/terms/maps-platform/eea) will apply to your use of the Services. Functionality varies by region. [Learn more](https://developers.google.com/maps/comms/eea/faq.md.txt).

> [!NOTE]
> **Building for navigation, delivery, rideshare, or physical arrival?**
>
> This page documents core coordinate and address lookup. If your application needs hyperlocal arrival data, such as **building entrances** , **routable navigation point tokens** , **2D building outlines (polygons)** , **sub-destinations** , or **nearby landmarks** , use [**Search for destinations**](https://developers.google.com/maps/documentation/geocoding/search-for-destinations.md.txt) (`SearchDestinations`) instead. To compare capabilities, see [Choose a geocoding method](https://developers.google.com/maps/documentation/geocoding/choose-a-method.md.txt).

*Reverse geocoding* translates a map location into a human-readable
address. You represent the map location by the latitude and longitude
coordinates of the location.

When you reverse geocode a location, the response contains the:

- [Place ID](https://developers.google.com/maps/documentation/places/web-service/place-id.md.txt) of the address
- [Plus Codes](https://maps.google.com/pluscodes/) of the address
- Address details

This API returns different types of addresses, from the most specific street
address to less specific political entities such as neighborhoods, cities,
counties, and states. The most exact address is generally the first result. If
you want to match a specific type of address, use the
[`types`](https://developers.google.com/maps/documentation/geocoding/reverse-geocoding.md.txt#types) parameter.

> [!NOTE]
> **Note:** Reverse geocoding is an estimate. The geocoder tries to find the closest addressable location within a certain tolerance. If the geocoder doesn't find a match, it returns zero results.

## Reverse geocoding request

A
[reverse geocoding](https://developers.google.com/maps/documentation/geocoding/reference/rest/v4/geocode.location.md.txt)
request is an HTTP GET request. You can specify the location
as an [unstructured string](https://developers.google.com/maps/documentation/geocoding/reverse-geocoding.md.txt#pass_an_unstructured_location_string):

```
https://geocode.googleapis.com/v4/geocode/location/LATITUDE,LONGITUDE
```

Or as a [structured](https://developers.google.com/maps/documentation/geocoding/reverse-geocoding.md.txt#pass_a_structured_location) set of latitude and longitude
coordinates represented by query parameters:

```html
https://geocode.googleapis.com/v4/geocode/location?location.latitude=LATITUDE&location.longitude=LONGITUDE
```

You typically use the structured format when processing location components
captured in an HTML form.

Pass all other parameters as URL parameters or, for parameters such as the API
key or field mask, in headers as part of the GET request. For example:

### Pass an unstructured location string

An unstructured location is a location formatted as a comma-separated string of
latitude and longitude coordinates:

```html
https://geocode.googleapis.com/v4/geocode/location/37.4225508,-122.0846338?key=API_KEY
```

Or in a curl command:

```
curl -X GET -H 'Content-Type: application/json' \
-H "X-Goog-Api-Key: API_KEY" \
"https://geocode.googleapis.com/v4/geocode/location/37.4225508,-122.0846338"
```

### Pass a structured location

Specify the structured location by using the `location` query parameter, of type
[`LatLng`](https://developers.google.com/maps/documentation/geocoding/reference/rest/Shared.Types/LatLng).
The `LatLng` object lets you specify the latitude and longitude as separate
query parameters:

```html
https://geocode.googleapis.com/v4/geocode/location?location.latitude=37.4225508&location.longitude=-122.0846338&key=API_KEY
```

### Use OAuth to make a request

Geocoding API v4 supports [OAuth
2.0](https://developers.google.com/maps/documentation/geocoding/oauth-token) for authentication. To use OAuth
with the Geocoding API, the OAuth token must be assigned the correct scope.
Geocoding API supports the following scopes for use with reverse geocoding:

- `https://www.googleapis.com/auth/maps-platform.geocode` --- Use with all Geocoding API methods.
- `https://www.googleapis.com/auth/maps-platform.geocode.location` --- Use only with `GeocodeLocation` for reverse geocoding.

Also, you can use the general `https://www.googleapis.com/auth/cloud-platform`
scope for all Geocoding API methods. That scope is useful during
development, but not production, because it is a general scope that allows
access to all methods.

For more information and examples, see [Use
OAuth](https://developers.google.com/maps/documentation/geocoding/oauth-token).

## Reverse geocoding response

Reverse geocoding returns a
[`GeocodeLocationResponse`](https://developers.google.com/maps/documentation/geocoding/reference/rest/v4/GeocodeLocationResponse.md.txt)
object that contains:

- The `results` array of
  [`GeocodeResult`](https://developers.google.com/maps/documentation/geocoding/reference/rest/v4/GeocodeResult.md.txt)
  objects that represents the place.

  The Geocoding API responses include `types` arrays in two main places within the
  [`GeocodeResult`](https://developers.google.com/maps/documentation/geocoding/reference/rest/v4/GeocodeResult.md.txt):
  1. **`GeocodeResult.types`** : This array indicates the overall type(s) of the result. The possible values are drawn from the Place types used by the Places API. For more information, see [Place types Tables A and B](https://developers.google.com/maps/documentation/places/web-service/place-types.md.txt).
  2. **`GeocodeResult.addressComponents[].types`** : Each address component has a `types` array indicating the type of that specific part of the address. These values are drawn from the [Address types and address component](https://developers.google.com/maps/documentation/places/web-service/place-types.md.txt#address-types) types table used by the Places API.

  The reverse geocoder returns more than one result in the `results` array.
  The results are not just postal addresses, but any way to geographically
  name a location. For example, when geocoding a point in the city of Chicago,
  the geocoded point may be denoted as a street address, as the city
  (Chicago), as its state (Illinois) or as a country (The United States). All
  are "addresses" to the geocoder. The reverse geocoder returns any of these
  types as valid results.
- The `plusCode` field, of type `PlusCode`, contains the Plus Code that best
  approximates the latitude and longitude in the request. In addition, each
  element of the `results` array contains a Plus Code. The distance between
  the decoded Plus Code and the request point is under 10 meters.

  Note: The API does not always return Plus Codes.

The complete JSON object is in the form:

```json
{
  "results": [
    {
      "place": "//places.googleapis.com/places/ChIJV-FZF7i7j4ARo4ZOUoecZFU",
      "placeId": "ChIJV-FZF7i7j4ARo4ZOUoecZFU",
      "location": {
        "latitude": 37.422588300000008,
        "longitude": -122.0846489
      },
      "granularity": "ROOFTOP",
      "viewport": {
        "low": {
          "latitude": 37.421239319708512,
          "longitude": -122.0859978802915
        },
        "high": {
          "latitude": 37.423937280291511,
          "longitude": -122.08329991970851
        }
      },
      "formattedAddress": "1600 Amphitheatre Pkwy, Mountain View, CA 94043, USA",
      "addressComponents": [
        {
          "longText": "1600",
          "shortText": "1600",
          "types": [
            "street_number"
          ]
        },
        {
          "longText": "Amphitheatre Parkway",
          "shortText": "Amphitheatre Pkwy",
          "types": [
            "route"
          ],
          "languageCode": "en"
        },
        {
          "longText": "Mountain View",
          "shortText": "Mountain View",
          "types": [
            "locality",
            "political"
          ],
          "languageCode": "en"
        },
        {
          "longText": "Santa Clara County",
          "shortText": "Santa Clara County",
          "types": [
            "administrative_area_level_2",
            "political"
          ],
          "languageCode": "en"
        },
        {
          "longText": "California",
          "shortText": "CA",
          "types": [
            "administrative_area_level_1",
            "political"
          ],
          "languageCode": "en"
        },
        {
          "longText": "United States",
          "shortText": "US",
          "types": [
            "country",
            "political"
          ],
          "languageCode": "en"
        },
        {
          "longText": "94043",
          "shortText": "94043",
          "types": [
            "postal_code"
          ]
        }
      ],
      "types": [
        "street_address"
      ],
      "plusCode": {
        "globalCode": "849VCW83+PM",
        "compoundCode": "CW83+PM Mountain View, CA, USA"
      }
    },
    {
      "place": "//places.googleapis.com/places/ChIJj61dQgK6j4AR4GeTYWZsKWw",
      "placeId": "ChIJj61dQgK6j4AR4GeTYWZsKWw",
      "location": {
        "latitude": 37.4220541,
        "longitude": -122.08532419999999
      },
      "granularity": "ROOFTOP",
      "viewport": {
        "low": {
          "latitude": 37.4207051197085,
          "longitude": -122.08667318029148
        },
        "high": {
          "latitude": 37.423403080291493,
          "longitude": -122.08397521970851
        }
      },
      "formattedAddress": "1600 Amphitheatre Pkwy, Mountain View, CA 94043, USA",
      "addressComponents": [
        {
          "longText": "1600",
          "shortText": "1600",
          "types": [
            "street_number"
          ]
        },
        {
          "longText": "Amphitheatre Parkway",
          "shortText": "Amphitheatre Pkwy",
          "types": [
            "route"
          ],
          "languageCode": "en"
        },
        {
          "longText": "Mountain View",
          "shortText": "Mountain View",
          "types": [
            "locality",
            "political"
          ],
          "languageCode": "en"
        },
        {
          "longText": "Santa Clara County",
          "shortText": "Santa Clara County",
          "types": [
            "administrative_area_level_2",
            "political"
          ],
          "languageCode": "en"
        },
        {
          "longText": "California",
          "shortText": "CA",
          "types": [
            "administrative_area_level_1",
            "political"
          ],
          "languageCode": "en"
        },
        {
          "longText": "United States",
          "shortText": "US",
          "types": [
            "country",
            "political"
          ],
          "languageCode": "en"
        },
        {
          "longText": "94043",
          "shortText": "94043",
          "types": [
            "postal_code"
          ]
        }
      ],
      "types": [
        "establishment",
        "point_of_interest"
      ],
      "plusCode": {
        "globalCode": "849VCWC7+RV",
        "compoundCode": "CWC7+RV Mountain View, CA, USA"
      }
    },
   ...
  ],
  "plusCode": {
    "globalCode": "849VCWF8+24H",
    "compoundCode": "CWF8+24H Mountain View, CA, USA"
  }
}
```

## Required parameters

-

  ### location

  The latitude and longitude coordinates specifying where
  you want the closest, human-readable address.

## Optional parameters

-

  ### languageCode

  The language in which to return results.
  - See the [list of supported languages](https://developers.google.com/maps/faq.md.txt#languagesupport). Google often updates the supported languages, so this list may not be exhaustive.
  - If `languageCode` isn't supplied, the API defaults to the local language and script of the location. If you specify an invalid language code, the API returns an `INVALID_ARGUMENT` error.
  - The API does its best to provide a street address that is readable for both the user and locals. To achieve that goal, it returns street addresses in the local language, transliterated to a script readable by the user if necessary, observing the preferred language. All other addresses are returned in the preferred language. Address components are all returned in the same language, which is chosen from the first component.
  - If a name is not available in the preferred language, the API uses the closest match.
  - The preferred language has a small influence on the set of results that the API chooses to return, and the order in which they are returned. The geocoder interprets abbreviations differently depending on language, such as the abbreviations for street types, or synonyms that may be valid in one language but not in another.
-

  ### regionCode

  The region code as a
  [two-character CLDR code](https://www.unicode.org/cldr/charts/latest/supplemental/territory_language_information.html) value. There is no default value. Most CLDR codes are identical to ISO 3166-1 codes.

  When geocoding an address, *forward geocoding* , this parameter can influence, but not
  fully restrict, results from the service to the specified region. When geocoding a location or a
  place, *reverse geocoding* or *place geocoding*, this parameter can be used to
  format the address. In all cases, this parameter can affect results based on applicable law.
-

  ### granularity

  One or more location granularities, specified as separate query parameters, as defined by `Granularity`.
  If you specify multiple `granularity` parameters, the API returns all addresses that match any of the granularities.

  The `granularity` parameter does not
  *restrict* the search to the specified location granularities. Rather,
  `granularity` acts as a post-search filter. The API fetches all
  results for the specified `location`, then discards those results
  that don't match the specified location granularities.

  If you specify both `types` and `granularity` then
  the API returns only those results that match both. For example:

  ```html
  https://geocode.googleapis.com/v4/geocode/location/37.4225508,-122.0846338?granularity=ROOFTOP&granularity=GEOMETRIC_CENTER&key=API_KEY
  ```
-

  ### types

  One or more address types, specified as separate query parameters. The
  possible values are drawn from the
  [Address
  types and address component types](https://developers.google.com/maps/documentation/places/web-service/place-types#address-types) table on the Place Types (New) page.
  If you specify multiple `types` parameters, the API returns
  all addresses that match any of the types.

  The `types` parameter does not
  *restrict* the search to the specified address type(s). Rather,
  `types` acts as a post-search filter. The API fetches all
  results for the specified location, then discards those results
  that don't match the specified address type(s).

  If you specify both `types` and `granularity` then
  the API returns only those results that match both. For example:

  ```html
  https://geocode.googleapis.com/v4/geocode/location/37.4225508,-122.0846338?types=administrative_area_level_2&types=locality&key=API_KEY
  ```
-

  ### FieldMask

  Create a [response field mask](https://developers.google.com/maps/documentation/geocoding/choose-fields.md.txt) to specify the fields to return in the response. Pass the response field mask to the method by using the URL parameter
  `$fields` or `fields`, or by using the HTTP header
  `X-Goog-FieldMask`. For example, the below request will return only the `placeID` fields of the response.

  ```curl
  curl -X GET -H 'Content-Type: application/json' \
  -H 'X-Goog-FieldMask: results.placeId' \
  -H "X-Goog-Api-Key: API_KEY" \
  "https://geocode.googleapis.com/v4/geocode/location/37.4225508,-122.0846338"
  ```
  The response is:

  ```json
  {
    "results": [
      {
        "placeId": "ChIJHRNUiQK6j4ARJ__Hrbt6qsE"
      },
      {
        "placeId": "ChIJj38IfwK6j4ARNcyPDnEGa9g"
      },
      {
        "placeId": "ChIJ1yjFJ1-7j4ARG_RVqFD1h7k"
      },
      {
        "placeId": "ChIJ09H2YwK6j4ARoF7qfCBxhB8"
      },
      ...
    ]
  }
  ```

  See [Choose fields to return](https://developers.google.com/maps/documentation/geocoding/choose-fields.md.txt) for more details.

  > [!IMPORTANT]
  > **Important:** Field masking is a good design practice to ensure that you don't request unnecessary data, which helps to avoid unnecessary processing time.