Everything an AI agent can do with the Google Maps API.

A reference guide for building AI agents: every method, how to authenticate, and the permissions each one needs.

Endpoints17
AuthenticationAPI key
Last updated23 June 2026
Orientation

How the Google Maps API works.

The Google Maps API is how an app or AI agent works with Google's geospatial data: turning an address into coordinates, finding nearby places, computing a route between two points, or looking up the time zone at a location. Access is granted through an API key, and the key is restricted in the Google Cloud Console to set which APIs it may call and which sites or addresses may use it. The web service APIs are read-oriented lookups, and they signal an empty or failed query through a status field in the response rather than only an HTTP error.

17Endpoints
5Capability groups
17Read
0Write
9Permissions
Authentication
Google Maps web service calls authenticate with an API key, not OAuth. The key is passed as a key query parameter on the older web services, or as an X-Goog-Api-Key header on the newer Places, Routes, and Address Validation APIs. There are no per-method scopes; what a key can do is set by the API restrictions placed on it in the Google Cloud Console.
Permissions
The boundary is the key restriction, set in the Google Cloud Console, not a scope sent with each request. An API key can be limited to specific APIs (so a Geocoding key cannot call Directions) and to specific HTTP referrers, IP addresses, or apps (so only an approved site or server can use it). A request outside those limits returns REQUEST_DENIED.
Data model
The classic web services (Geocoding, Directions, Distance Matrix, Time Zone, Elevation) are GET requests that take parameters in the URL and return JSON with a status field. The newer Places, Routes, and Address Validation APIs are mostly POST requests with a JSON body and require an X-Goog-FieldMask header naming which fields to return. None of these write to a customer's data.
Versioning
The older web services are unversioned and addressed by path under /maps/api. The newer APIs carry a path version, like Places and Address Validation at /v1 and Routes at /directions/v2. There is no per-account pinned version; Google ships changes through dated release notes and keeps the stable web services backward-compatible.
Connect & authenticate

Connection & authentication methods.

How an app or AI agent connects to Google Maps determines what it can reach. There is the set of web service APIs called with an API key, and a hosted server that exposes a subset of Maps tools to agents, and each is governed by the key behind it and the APIs that key is allowed to call.

Ways to connect

Web service APIs

The Google Maps Platform web service APIs are HTTPS endpoints called directly with an API key. The older services (Geocoding, Directions, Distance Matrix, Time Zone, Elevation, Roads) are GET requests under maps.googleapis.com/maps/api and roads.googleapis.com, with the key in the URL. The newer services (Places API (New), Routes, Address Validation) are mostly POST requests to their own host with the key in an X-Goog-Api-Key header and a required X-Goog-FieldMask header.

Best forConnecting an app or AI agent to Google Maps data.
Governed byThe API key and the API and application restrictions set on it in the Google Cloud Console.
Docs ↗

MCP server (Maps Grounding Lite)

Google publishes a hosted Model Context Protocol server at https://mapstools.googleapis.com/mcp, through Maps Grounding Lite, that exposes a focused set of Maps tools to AI agents and MCP clients: search_places, compute_routes, resolve_names, resolve_maps_urls, and lookup_weather. It is enabled on a Google Cloud project and authenticated with that project's credentials, the same key-and-restriction model as the web service APIs.

Best forGrounding an AI agent's answers in real Google Maps data through MCP.
Governed byThe Google Cloud project credential and the APIs enabled on it.
Docs ↗
Authentication

API key

An API key is a single string that identifies the calling project. The older web services take it as a key query parameter in the URL; the newer Places, Routes, and Address Validation APIs take it as an X-Goog-Api-Key header. The key carries no per-method scopes. Its reach is set entirely by the restrictions placed on it in the Google Cloud Console: which APIs it may call, and which HTTP referrers, IP addresses, or apps may use it.

TokenAPI key (a project-level key string)
Best forCalling the Google Maps web service APIs from an app, server, or agent.
Docs ↗
Endpoint reference

Every Google Maps API method.

Filter by method, access, or permission, or search any path. Select a row for version detail, rate limits, the related webhook event, and the source.

MethodEndpointWhat it doesAccessPermissionVersion

Geocoding

Methods for converting between addresses and geographic coordinates.3

Read-only. Key must be allowed to call the Geocoding API.

Acts ongeocode
Permission (capability)Geocoding API
VersionAvailable since the API’s base version
Webhook eventNone
Rate limitStandard limits apply

Read-only. Same endpoint as forward geocoding, using latlng instead of address.

Acts ongeocode
Permission (capability)Geocoding API
VersionAvailable since the API’s base version
Webhook eventNone
Rate limitStandard limits apply

Read-only validation. POST with a JSON address body; key sent as a query parameter or header.

Acts onaddress
Permission (capability)Address Validation API
VersionAvailable since the API’s base version
Webhook eventNone
Rate limitStandard limits apply

Places

Methods for finding places and reading their details, on the Places API (New).5

Read-only. Requires an X-Goog-FieldMask header naming the fields to return; the field mask sets the billing tier.

Acts onplace
Permission (capability)Places API
VersionAvailable since the API’s base version
Webhook eventNone
Rate limitStandard limits apply

Read-only. POST only; requires an X-Goog-FieldMask header.

Acts onplace
Permission (capability)Places API
VersionAvailable since the API’s base version
Webhook eventNone
Rate limitStandard limits apply

Read-only. Requires an X-Goog-FieldMask header (or fields parameter) naming the fields to return.

Acts onplace
Permission (capability)Places API
VersionAvailable since the API’s base version
Webhook eventNone
Rate limitStandard limits apply

Read-only. POST with the partial input in the JSON body; can use a session token to group keystrokes for billing.

Acts onplace
Permission (capability)Places API
VersionAvailable since the API’s base version
Webhook eventNone
Rate limitStandard limits apply

Read-only. The photo resource name comes from a Place Details, Text Search, or Nearby Search response.

Acts onphoto
Permission (capability)Places API
VersionAvailable since the API’s base version
Webhook eventNone
Rate limitStandard limits apply

Routes & Distance

Methods for computing routes and travel distances and times between points.4

Read-only. The Routes API computeRoutes is the newer replacement for new integrations.

Acts onroute
Permission (capability)Directions API
VersionAvailable since the API’s base version
Webhook eventNone
Rate limitStandard limits apply

Read-only. Billed by element (origins times destinations). The Routes API computeRouteMatrix is the newer replacement.

Acts ondistance_matrix
Permission (capability)Distance Matrix API
VersionAvailable since the API’s base version
Webhook eventNone
Rate limitStandard limits apply

Read-only. POST with a JSON body; requires an X-Goog-FieldMask header. Replaces the legacy Directions API.

Acts onroute
Permission (capability)Routes API
VersionAvailable since the API’s base version
Webhook eventNone
Rate limitStandard limits apply

Read-only. POST with a JSON body and an X-Goog-FieldMask header. Replaces the legacy Distance Matrix API.

Acts onroute_matrix
Permission (capability)Routes API
VersionAvailable since the API’s base version
Webhook eventNone
Rate limitStandard limits apply

Roads

Methods for snapping GPS traces to roads and reading speed limits.3

Read-only. Accepts up to 100 points per request via the path parameter.

Acts onroad
Permission (capability)Roads API
VersionAvailable since the API’s base version
Webhook eventNone
Rate limitStandard limits apply

Read-only. Takes a points parameter of coordinates.

Acts onroad
Permission (capability)Roads API
VersionAvailable since the API’s base version
Webhook eventNone
Rate limitStandard limits apply

Read-only. Available on Asset Tracking plans; takes place IDs or a path of points.

Acts onspeed_limit
Permission (capability)Roads API
VersionAvailable since the API’s base version
Webhook eventNone
Rate limitStandard limits apply

Location context

Methods for looking up the time zone, elevation, or validity of a location.2

Read-only. Takes a location and a timestamp.

Acts ontimezone
Permission (capability)Time Zone API
VersionAvailable since the API’s base version
Webhook eventNone
Rate limitStandard limits apply

Read-only. Takes a locations parameter, or a path and samples for elevation along a line.

Acts onelevation
Permission (capability)Elevation API
VersionAvailable since the API’s base version
Webhook eventNone
Rate limitStandard limits apply
No endpoints match those filters.
Webhooks

Webhook events.

EventWhat it signalsTriggered by
No events match that search.
Rate limits & pagination

Rate limits, pagination & request size.

Google Maps meters each API by a queries-per-minute and, on some APIs, a queries-per-second ceiling, set per project in the Google Cloud Console, and bills per call against a monthly volume.

Request rate

Google Maps meters each API independently, set per project in the Google Cloud Console. Most web services default to a queries-per-minute ceiling, like 3,000 per minute, and some also enforce a queries-per-second limit, like 25 per second on Geocoding. The Roads API has its own ceiling. A project can request higher quotas, and going over returns the OVER_QUERY_LIMIT status (or HTTP 429 on the newer APIs). Billing is pay-per-call against monthly volume, so a custom daily quota can be set in the Console to cap spend.

Pagination

The search APIs return a bounded page rather than a cursor over everything. A legacy Places Text Search or Nearby Search returns up to 20 results per page and up to 60 in total, fetched with a next_page_token. Places API (New) returns up to 20 places per call, raised with a pageSize parameter and continued with a pageToken. Geocoding, Directions, and the lookup APIs return their full result set in one response.

Request size

Limits are per request, not per page. A request URL is capped at 16,384 characters across the web services. Snap to Roads accepts up to 100 GPS points per call, a Distance Matrix request is bounded by origins times destinations elements, and Places API (New) caps a single search at 20 results unless pageSize is raised.

Errors

Status codes & error handling.

The status codes an agent should handle, and what to do about each.

StatusCodeMeaningWhat to do
200ZERO_RESULTSOn the classic web services, the request succeeded with HTTP 200 but the query matched no results, like an address that could not be located or a route that could not be built.Treat it as an empty result, not a failure. Check the input parameters and widen the query if a match was expected.
200OVER_QUERY_LIMITThe project has exceeded its rate limit (queries per second or per minute) for that API. Returned with HTTP 200 and this status on the classic web services.Back off and retry with exponential backoff, smooth the request rate, or raise the quota for the API in the Google Cloud Console.
200REQUEST_DENIEDThe request was refused: the API key is missing or invalid, the key is not allowed to call this API, billing is not enabled, or the request was sent over HTTP instead of HTTPS.Confirm a valid key is sent, that the key's API restrictions include this API, that billing is enabled, and that the request uses HTTPS.
200INVALID_REQUESTThe request was malformed, usually a missing or invalid required parameter, like an address or location that was not supplied.Check the required parameters for that API and resend; the request is not retryable as-is.
403PERMISSION_DENIEDOn the newer Places, Routes, and Address Validation APIs, the key is not authorized for the request, for example the API is not enabled on the project or the key's restrictions exclude it.Enable the API on the project and confirm the key's API and application restrictions allow this call.
429RESOURCE_EXHAUSTEDOn the newer APIs, the per-minute or per-second quota for the project has been exhausted.Retry with exponential backoff and request a higher quota in the Google Cloud Console if the limit is hit consistently.
400INVALID_ARGUMENTOn the newer APIs, the request body or parameters were invalid, including a missing X-Goog-FieldMask header where one is required.Validate the JSON body and include a valid field mask naming the fields to return, then resend.
Versioning & freshness

Version history.

The core Google Maps web service APIs are unversioned and addressed by path; newer APIs like Places, Routes, and Address Validation carry a version segment in their path, and changes ship through dated release notes rather than a pinned account version.

Version history

What changed, and when

Latest versionCurrent
CurrentCurrent version
Google Maps Platform web service APIs

The classic web services (Geocoding, Directions, Distance Matrix, Time Zone, Elevation, Roads) are unversioned and addressed by path under /maps/api; the newer services carry a path version (Places and Address Validation at /v1, Routes at /directions/v2). There is no per-account pinned version. Google ships changes through dated release notes and keeps the stable web services backward-compatible.

What changed
  • Places API (New) and Routes API are the current generation, using POST with a required X-Goog-FieldMask header.
  • The legacy Places API (GET under /maps/api/place) remains served but no longer receives new features.
  • Maps Grounding Lite added a hosted MCP server at mapstools.googleapis.com/mcp for AI agents.
2025-mcp
Official MCP support for Google Maps Platform

Google released hosted, remote Model Context Protocol servers for Google services, including Maps Grounding Lite at mapstools.googleapis.com/mcp, giving AI agents a managed endpoint for places, routing, and weather grounding.

What changed
  • Maps Grounding Lite MCP server exposes search_places, compute_routes, resolve_names, resolve_maps_urls, and lookup_weather.
  • A separate Code Assist MCP server (mapscodeassist.googleapis.com) grounds developer tooling in Maps documentation.
places-new
Places API (New) and Routes API

Google introduced the rebuilt Places API (New) under places.googleapis.com/v1 and the Routes API under routes.googleapis.com, both using POST requests with a required X-Goog-FieldMask header, replacing the legacy GET-based Places and Directions and Distance Matrix services for new integrations.

What changed
  • Places API (New): searchText, searchNearby, place details, autocomplete, and photos, with field masks setting the response and billing tier.
  • Routes API: computeRoutes and computeRouteMatrix replace the legacy Directions and Distance Matrix services.

Track the release notes; the older web services stay backward-compatible while newer ones add features under their own path version.

Google Maps Platform release notes ↗
Questions

Google Maps API, answered.

Does the Google Maps API use OAuth and scopes?+
The web service APIs authenticate with an API key, not OAuth, and there are no per-method scopes. What a key may do is set by the API restrictions on it in the Google Cloud Console: a key can be limited to specific APIs and to specific HTTP referrers, IP addresses, or apps. Some newer services also accept OAuth tokens, but the standard and documented path for these web services is an API key.
What is the difference between Places API and Places API (New)?+
Places API (New) is the rebuilt version. It uses POST requests to places.googleapis.com under /v1, requires an X-Goog-FieldMask header that names which fields to return (and so which billing tier applies), and authenticates with the X-Goog-Api-Key header. The legacy Places API uses GET requests under /maps/api/place with the key in the URL. New integrations should use Places API (New); the legacy endpoints are still served but no longer get new features.
How does Google Maps signal that a query found nothing or failed?+
The classic web services return HTTP 200 with a status field in the body. OK means results were returned, ZERO_RESULTS means the query was valid but matched nothing, OVER_QUERY_LIMIT means the project is over quota, and REQUEST_DENIED means the key is missing, invalid, or not allowed to call that API. The newer Places, Routes, and Address Validation APIs use standard HTTP status codes and a Google error body instead.
Are there webhooks or events?+
No. The Google Maps web service APIs are request-and-response lookups with no event or webhook model. An app or agent calls an endpoint and reads the result; there is nothing for Maps to push back. To watch for change, an integration polls the relevant API on its own schedule.
How is the Google Maps API priced and rate-limited?+
Each API is billed per call against monthly volume, with the price depending on the API and, for Places, the fields requested through the field mask. Rate limits are set per project in the Google Cloud Console as a queries-per-minute and, on some APIs, a queries-per-second ceiling. A custom daily quota can be set to cap spend, and exceeding the rate limit returns OVER_QUERY_LIMIT or HTTP 429.
Is there an official Google Maps MCP server for AI agents?+
Yes. Google publishes a hosted Model Context Protocol server through Maps Grounding Lite at mapstools.googleapis.com/mcp. It exposes a focused set of tools, search_places, compute_routes, resolve_names, resolve_maps_urls, and lookup_weather, designed to ground an AI agent's answers in real Maps data. It is enabled and authenticated through a Google Cloud project, the same key-and-restriction model as the web service APIs.
Related

More maps API guides for agents

What is Bollard AI?

Control what every AI agent can do with Google Maps.

Bollard AI sits between a team's AI agents and Google Maps. Grant each agent only the Maps capabilities it needs, geocoding, places, or routing, and every call is checked and logged.

  • Allow only the specific APIs an agent needs, never a shared, unrestricted Maps key.
  • Denied by default, so an agent reaches only what has been explicitly allowed.
  • Every call recorded in plain English: who, what, where, and the decision.
Google Maps
Logistics Agent
Geocode addresses ActionOffReadFull use
Find places ResourceOffReadFull use
Compute routes ActionOffReadFull use
Per-agent access, set in Bollard AI, not in Google Cloud