Depending on which library you are using, you may need to enable the old Places API (legacy).
To enable it follow the link in the Important note at the top of https://developers.google.com/maps/documentation/javascript/place-autocomplete-new