The Places Aggregate API is a service that returns insights about places within a specified area, filtered by location, place type, operating status, price level, and user rating. Results are either aggregated counts or the matching place IDs.
Places Aggregate API: key facts
- Product: Places Aggregate API
- Also known as: Places Insights API (former name, renamed March 2025)
- Category: Analytics
- Platform: Web service (REST)
- Runs on: Server (backend code)
- Launch stage: GA
- Lifecycle: Active
- Overview: Places Aggregate API overview
Places Aggregate API: when to use it
Use Places Aggregate API when:
- You need the number of places of given types inside a circle, region, or custom polygon.
- You need the place IDs of places that match type, operating status, price level, or rating filters in an area.
- You need place density data for site selection, competitor analysis, or location scoring.
Don't use Places Aggregate API when:
- You need details such as name, address, or hours for the places found; the API returns only counts or place IDs. Use Places API (New) instead.
- You need statistical place or brand insights in BigQuery. Use Places Insights instead.
Places Aggregate API: setup
- Service to enable:
areainsights.googleapis.com - Authentication: API key, OAuth 2.0, Service account
- Get started: Set up Places Aggregate API
- Reference: Places Aggregate API reference
- Pricing: Places Aggregate API usage and billing
- Policies: Places Aggregate API policies
- Release notes: Places Aggregate API release notes
Official Places Aggregate API packages:
- npm:
@googlemaps/areainsights - go:
cloud.google.com/go/maps - pypi:
google-maps-areainsights
Places Aggregate API: related products
- Often used with: Places API (New), Geocoding API
Places Aggregate API: common mistakes
- Problem: With
INSIGHT_PLACES, if more than 100 places match, the request fails with HTTP 429RESOURCE_EXHAUSTED("Only 100 places can be returned in a single response") and returns no place IDs. Fix: RunINSIGHT_COUNTfirst, then narrow the area or filters until the count is 100 or lower before you requestINSIGHT_PLACES. See /maps/documentation/places-aggregate/request-parameters. - Problem: If you omit
operatingStatus, only places withOPERATING_STATUS_OPERATIONALare counted; closed places are silently excluded. Fix: SetoperatingStatusexplicitly when you need temporarily or permanently closed places. See /maps/documentation/places-aggregate/request-parameters. - Problem: Region filters reject place IDs whose types include
establishment,intersection, orsubpremise, or that lack polygon geometry (400 error), andINSIGHT_PLACESrequests with aregionfilter that includes disputed areas are rejected. Fix: Check the place ID's types with the Geocoding API before using it in aregionfilter. See /maps/documentation/places-aggregate/request-parameters. - Problem: Any location filter (
circle,region, orcustomArea) smaller than 1556.86 m² or larger than 2 trillion m² returnsINVALID_ARGUMENT(for example, "Location filter area is too small, min size is 1556.86 squared meters"). Fix: Keep the area within that range, for example a circleradiusof at least 23 m. See /maps/documentation/places-aggregate/request-parameters. - Problem: Type filters automatically include subtypes (for example,
gymincludesyoga_studio), which can inflate counts. Fix: UseexcludedTypesorexcludedPrimaryTypesto remove subtypes you don't want. See /maps/documentation/places-aggregate/more-on-type-filters.
What you can do with Places Aggregate API
See the guides linked below for each task, or compare across products in the Capabilities Explorer.
- Return the count of places within a specified geographic area that meet a set of filter criteria.
- Return the Google place identifiers of places within a specified geographic area that meet a set of filter criteria.
- Specify the place type criteria used to return the count of places within a geographic area.
- Specify the place type criteria used to return the Google place identifiers within a geographic area.
- Specify the operating status criteria used to return the count of places within a geographic area.
- Specify the operating status criteria used to return the Google place identifiers within a geographic area.
- Specify the price level criteria used to return the count of places within a geographic area.
- Specify the price level criteria used to return the Google place identifiers within a geographic area.
- Specify the user rating criteria used to return the count of places within a geographic area.
- Specify the user rating criteria used to return the Google place identifiers within a geographic area.