Restrict Google Places Autocomplete to return addresses only

randomguy picture randomguy · Feb 25, 2013 · Viewed 9.6k times · Source
autocomplete = new google.maps.places.Autocomplete(input, { types: ['geocode'] });

returns streets and cities amongst other larger areas. Is it possible to restrict to streets only?

Answer

spiv picture spiv · May 7, 2015

I think what you want is { types: ['address'] }.

You can see this in action with this live sample: https://developers.google.com/maps/documentation/javascript/examples/places-autocomplete (use the "Addresses" radio button).