Migrate to Autocomplete (New)

European Economic Area (EEA) developers If your billing address is in the European Economic Area, effective on 8 July 2025, the Google Maps Platform EEA Terms of Service will apply to your use of the Services. Functionality varies by region.Learn more.

Introduction

Places API supports thePlace Autocomplete (Legacy)andQuery Autocomplete (Legacy) APIs.If you are familiar with these APIs, Autocomplete (New) makes the following changes:

  • Autocomplete (New) uses HTTP POST requests. Pass parameters in the request body or in headers as part of an HTTP POST request. In contrast, with the legacy APIs, you pass URL parameters using an HTTP GET request.
  • Autocomplete (New) supports bothAPI keys andOAuth tokens as the authentication mechanism.
  • Only JSON is supported as a response format in Autocomplete (New).

The following table lists parameters in Place Autocomplete (Legacy) and Query Autocomplete (Legacy) that have been renamed or modified for Autocomplete (New), or parameters that are no longer supported.

Current parameterNew parameterNotes
componentsincludedRegionCodes
languagelanguageCode
locationlocationBias
ipbiasIf you omit bothlocationBias andlocationRestriction, then the API uses IP biasing by default.
offsetinputOffset
radiuslocationBias orlocationRestriction
regionregionCode
stricboundslocationRestriction
sessiontokensessionToken
typesincludedPrimaryTypes

Example request

The following example GET request uses Place Autocomplete (Legacy). In thisexample, you request a JSON response containing information about places called"Amoeba" that are of typeestablishment and pass all parameters as URLparameters:

curl -L -X GET 'https://maps.googleapis.com/maps/api/place/autocomplete/json?input=amoeba&types=establishment&location=37.76999%2C-122.44696&radius=500&key=YOUR_API_KEY'

With Autocomplete (New), you make a POST request and pass all parametersin the JSON request body or in headers as part of the POST request.

Field masks are not required for Autocomplete (New) requests, but they canbe used to filter for specific results in the response. For example, thefollowing request uses a field mask so the response only includes thesuggestions.placePrediction.text of the suggestion:

curl -X POST -d '{  "input": "Amoeba",  "locationBias": {    "circle": {      "center": {        "latitude": 37.76999,        "longitude": -122.44696      },      "radius": 500.0    }  }}' \-H 'Content-Type: application/json' -H 'X-Goog-Api-Key:API_KEY' \-H 'X-Goog-FieldMask: suggestions.placePrediction.text' \https://places.googleapis.com/v1/places:autocomplete

To learn more about using field masks, seePlace Details (New).

Except as otherwise noted, the content of this page is licensed under theCreative Commons Attribution 4.0 License, and code samples are licensed under theApache 2.0 License. For details, see theGoogle Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates.

Last updated 2025-11-21 UTC.