This document lists requirements for applications developed with the
Maps JavaScript API. Note that use of the Maps JavaScript API is governed by
your Agreement with Google.

## Policies

This section describes policies relevant to Maps JavaScript API. Policies provide practical
implementation guidelines and requirements to help you use the Service
correctly and in line with Google Maps Platform's expectations.

### Data storage, caching, and scraping

When using Google Maps Content in your application, follow the data
handling requirements in Section 3.2.3 of the
[Google Maps Platform Terms of Service](https://cloud.google.com/maps-platform/terms#3.-license.)
and the
[Google Maps Platform Service Specific Terms](https://cloud.google.com/maps-platform/terms/maps-service-terms):

- **Caching and scraping restrictions (Section 3.2.3(a) and
  (b)):** Cache or store Google Maps Content only as expressly permitted under the [Google Maps Platform Service Specific Terms](https://cloud.google.com/maps-platform/terms/maps-service-terms). Don't export, extract, or scrape Google Maps Content for use outside the Services. For example, don't pre-fetch, index, store, or redistribute Google Maps Content outside the Services; bulk download map tiles, Street View images, geocodes, directions, distance matrix results, roads information, places information, elevation values, or time zone details; or copy and save business names, addresses, or user reviews.
- **Derived content restrictions (Section 3.2.3(c)):** Use Google Maps Content within your application as permitted by the [Google Maps Platform Terms of Service](https://cloud.google.com/maps-platform/terms#3.-license.). Don't create content based on Google Maps Content. For example, don't trace or digitize features from satellite imagery, build 3D or terrain models, use Places latitude and longitude values as input for point-in-polygon analysis, construct a location index from Street View imagery, or convert text-based driving times into synthesized speech.

To reduce latency and billing costs without caching restricted data, use
field masks or field lists to request only the fields that your user
interface needs. Store exempt identifiers such as the place ID to fetch fresh
details when a user interacts with a place.

Google technical support engineers can't provide legal advice or grant
exceptions to the Google Maps Platform Terms of Service. Consult your legal counsel to
determine whether your implementation complies with the terms, or
[contact Sales](https://cloud.google.com/contact-maps)
if your use case requires custom licensing.

### Exceptions from caching restrictions

The [Google Maps Platform Service Specific Terms](https://cloud.google.com/maps-platform/terms/maps-service-terms)
grant the following limited caching exceptions:

- **Place IDs:** The **place ID** , used to uniquely identify a place, is **exempt from** the [caching restrictions](https://cloud.google.com/maps-platform/terms/maps-service-terms). You can therefore store place ID values indefinitely. Place IDs are returned in the [`id`](https://developers.google.com/maps/documentation/places/web-service/reference/rest/v1/places.md.txt#Place.FIELDS.id) or [`place_id`](https://developers.google.com/maps/documentation/places/web-service/legacy/details.md.txt#Place-place_id) field in API responses. Learn how to save, refresh, and manage place IDs in the [Place IDs guide](https://developers.google.com/maps/documentation/places/web-service/place-id.md.txt#save-id).
- **Latitude and longitude coordinates:** You can temporarily cache latitude ([`latitude`](https://developers.google.com/maps/documentation/places/web-service/reference/rest/v1/places.md.txt#LatLng.FIELDS.latitude)) and longitude ([`longitude`](https://developers.google.com/maps/documentation/places/web-service/reference/rest/v1/places.md.txt#LatLng.FIELDS.longitude)) values for up to 30 consecutive calendar days, after which you must delete the cached coordinates, when using services that grant this exception in the [Google Maps Platform Service Specific Terms](https://cloud.google.com/maps-platform/terms/maps-service-terms):
  - Routes API, Route Optimization API, Directions API (Legacy), and Roads API
  - Geocoding API, Geolocation API, and Address Validation API
  - Places API, Places UI Kit, and Navigation SDK
- **Service-specific caching periods:** The [Google Maps Platform Service Specific Terms](https://cloud.google.com/maps-platform/terms/maps-service-terms) also define field-specific caching periods and permitted purposes for the Address Validation API, Air Quality API, Pollen API, Solar API, Weather API, and Places Aggregate API.

### Content scraping

Place Name may be returned to you based on user interactions with your app.
If you were to capture or persist the Place Name for use in any other context
outside of the user session, this would constitute scraping, which is not
allowed by our terms.

### European Economic Area countries and territories

This product has different Terms of Service for customers with a billing address in the
European Economic Area (EEA), and it may also have different functionality.
Before building with Google Maps Platform, review the following EEA-specific
terms and information:

- [Google Maps Platform EEA Terms of Service](https://cloud.google.com/terms/maps-platform/eea)
- [Google Maps Platform EEA Service Specific Terms](https://cloud.google.com/terms/maps-platform/eea/maps-service-terms)
- [EEA frequently asked questions (FAQ)](https://developers.google.com/maps/comms/eea/faq.md.txt)
- [Google Maps Platform Road Safety Requirements](https://cloud.google.com/terms/maps-platform/eea-safety-requirements)

If your billing address is not in the EEA, the following terms of service apply to you:

- [Google Maps Platform Terms of Service](https://cloud.google.com/maps-platform/terms)
- [Google Maps Platform Service Specific Terms](https://cloud.google.com/maps-platform/terms/maps-service-terms)

## Google Maps attribution requirements

This section provides attribution requirements and guidelines for displaying Google
Maps and Content through your applications.

> [!NOTE]
> **Note:** The following updated attribution requirements now use "Google Maps" instead of only "Google." We acknowledge that your existing implementations may use the attribution of "Google," in alignment with prior guidance, and you may continue using "Google" as an attribution for now. For new implementations, use "Google Maps" as described in this section. In the future, we will provide timelines and instructions to help you transition existing "Google" attributions to "Google Maps" attributions.

### Attribution example

Following is an attribution example for Places UI Kit.
![Places UI Kit
attribution example on a non-Google map](https://developers.google.com/static/maps/images/non-google-map-places-ui-kit-attribution.png) Required attribution applied to the Place Details compact component. On this non-Google map, the Google Maps attribution is clearly visible, and Google Maps Platform content is visually differentiated from other content.

### Display Google Maps attribution

You must follow Google Maps attribution requirements when displaying Content from
Google Maps Platform APIs in your app or website. You don't need to add extra attribution
if the Content is shown on a Google Map where the attribution is already visible.

### Included Google Maps attribution

For Google Maps attribution that is already provided by Google Maps Platform in
the user interface, such as in Places UI Kit:

- Don't remove included attribution regardless of where it is displayed. Don't alter, hide, or obscure the attribution and make sure it is clearly visible against the background.
- Always visually distinguish Google Maps Platform Content from other content by using UI cues such as a border, background color, shadow, or sufficient whitespace.
- When making visual modifications, you must adhere to all Google Maps attribution requirements.

### Google Maps logo and text attribution

Attribution should take the form of the Google Maps logo whenever possible.
In cases where space is limited, the text **Google Maps** is acceptable.
It must always be clear to end users which content is provided by Google Maps.
![Left: Google Maps logo attribution, Right: Google Maps text attribution](https://developers.google.com/static/maps/images/01_GMP_Logo_Text.png) Left: Example of Google Maps logo attribution, Right: Example of Google Maps text attribution

### Logo attribution

Follow these requirements for using the Google Maps logo in your app or website. ![Acceptable variations for Google Maps logo attribution](https://developers.google.com/static/maps/images/02_GMP_Logo_Alternates.svg) Examples of acceptable variations for Google Maps logo attribution

#### Download Google Maps logos

Use the official Google Maps logo files. Download the logos below, and follow the guidelines in this section.
[Download the Google Maps attribution assets](https://developers.google.com/static/maps/documentation/images/Google_Maps_Attribution_Assets.zip)

When using the Google Maps logo, follow these guidelines.

- Don't modify the logo in any way.
- Maintain the aspect ratio of the logo to prevent distortion.
- Use the outlined logo on a busy background, like a map or image.
- Use the non-outlined logo on a plain background, like a solid color or subtle gradient.

#### Logo size specification

Follow these size specifications for the Google Maps logo:

- **Minimum logo height:** 16dp
- **Maximum logo height:** 19dp
- **Minimum logo clear space:** 10dp on left, right and top, 5dp on the bottom

To learn about dp, see [Pixel density](https://m2.material.io/design/layout/pixel-density.html#pixel-density) on the Material Design website.
![Google Maps logo showing minimum clear space and acceptable size range](https://developers.google.com/static/maps/images/03_GMP_Logo_Clear.svg) Example of Google Maps logo showing minimum clear space and acceptable size range

#### Logo accessibility

Follow these accessibility requirements for the Google Maps logo:

- Maintain an [accessible contrast](https://www.w3.org/WAI/WCAG21/Understanding/contrast-minimum.html) between the logo and the background.
- Include an accessibility label with the text **Google Maps**.

![Unacceptable variations and accessibility issues for Google Maps logo attribution](https://developers.google.com/static/maps/images/04_GMP_Logo_Accessibility.svg) Examples of unacceptable variations and accessibility issues for Google Maps logo attribution

### Text attribution

If the size of your interface does not support using the Google Maps logo, you can spell out **Google Maps** in text. Follow these guidelines:
![Acceptable variations of the Google Maps text attribution](https://developers.google.com/static/maps/images/05_GMP_Text_Attribution.svg) Examples of acceptable variations of the Google Maps text attribution

- Don't modify the text **Google Maps** in any way:  
  - Don't change the capitalization of **Google Maps**
  - Don't wrap **Google Maps** onto multiple lines
  - Don't localize **Google Maps** into another language.
  - Prevent browsers from translating **Google Maps** by using the HTML attribute `translate="no"`.

![Unacceptable variations of the Google Maps text attribution](https://developers.google.com/static/maps/images/06_GMP_Text_Donts.svg) Examples of unacceptable variations of the Google Maps text attribution

- Style Google Maps text as described in the following table:

  | Google Maps text-styling requirements ||
  |---|---|
  | **Property** | **Style** |
  | Font family | [Roboto](https://fonts.google.com/specimen/Roboto?preview.text_type=custom). Loading the font is optional. |
  | Fallback font family | Any sans serif body font already used in your product or "Sans-Serif" to invoke the default system font |
  | Font style | Normal |
  | Font weight | 400 |
  | Font color | White, black (#1F1F1F), or gray (#5E5E5E). Maintain accessible [(4.5:1)](https://www.w3.org/WAI/WCAG21/Understanding/contrast-minimum.html) contrast against the background. |
  | Font size | Minimum font size: 12sp Maximum font size: 16sp To learn about sp, see [Font size units](https://m3.material.io/styles/typography/type-scale-tokens#3f4488e7-3b74-45b0-a143-9d6afa4d62dc) on the Material Design website. |
  | Letter spacing | Normal |

#### Example CSS

The following CSS renders Google Maps with the appropriate typographic style and color on a white or light background.

```javascript
@import url('https://fonts.googleapis.com/css2?family=Roboto&display=swap');

.GMP-attribution {
font-family: Roboto, Sans-Serif;
font-style: normal;
font-weight: 400;
font-size: 1rem;
letter-spacing: normal;
white-space: nowrap;
color: #5e5e5e;
}
```

### Visual requirements

Follow these requirements for the visual treatment of Google Maps attribution.

- Position attribution near the top or bottom of the content, and within the same visual container. For a single line of content, attribution can be positioned to the right or left.

- Visually distinguish Google Maps Platform Content from other content by using UI cues such as a border, background color, shadow, or sufficient whitespace.

- Don't misrepresent Google Maps by attributing it with non-Google Maps Platform content.
- Verify that the attribution is always visible and legible. Never remove, hide, obscure, or modify it.

The following figures show examples of these visual requirements.
![Example of Google Maps attribution positioned at the top, at the bottom, and to the side of the content](https://developers.google.com/static/maps/images/07_GMP_Attribution_Placement.png) Example of Google Maps attribution positioned at the top, at the bottom, and to the side of the content   
![Example of two approaches to differentiating Google Maps Content (the place rating) from other content](https://developers.google.com/static/maps/images/08_GMP_Attribution_Separation.svg) Example of two approaches to differentiating Google Maps Content (the place rating) from other content   
![Don't obscure the Google Maps attribution or mix it with content from other sources](https://developers.google.com/static/maps/images/09_GMP_Attribution_position_donts.png) Don't obscure the Google Maps attribution or mix it with content from other sources

### Third-party data providers

Some of the data and images on our mapping products come from providers other than Google.
For some products, such as Map Tiles API, we may provide you with the required attribution
to the third-party data provider. When we do, the text of your
attribution must say the name "Google Maps" and the relevant
data provider(s), such as "Map data: Google, Maxar Technologies." When Google provides
third-party attribution, only including "Google Maps" or the Google logo is not
proper attribution.

## Other attribution requirements

Follow these instructions to retrieve third-party attributions, and to display
the attributions in your app.

> [!NOTE]
> Reviews and photos provided through the Maps JavaScript API are subject to Google's content and product policies wherever you are in the world. To report content that you or your users would like removed from Google's services under Google's policies or applicable laws, see [Report Content On Google](https://support.google.com/legal/troubleshooter/1114905#ts=9723198%2C7170398)

### Retrieve attributions from a Place

If your app displays review information obtained by calling
[`Place.fetchFields`](https://developers.google.com/maps/documentation/javascript/place-details.md.txt),
the app must also display third-party attributions for the place details obtained.

The API returns a [`Place`](https://developers.google.com/maps/documentation/javascript/reference/place.md.txt)
object. To retrieve attributions from the `Place` object, use the
[`Place.attributions`](https://developers.google.com/maps/documentation/javascript/reference/place.md.txt#Place.attributions)
property, which is returned with every request (there is no need to specify it with fields). The
property returns a `List` of `String` objects, or `null` if there
are no attributions to display. The following example code shows getting a place, and listing any
attributions.

```javascript
  // Use place ID to create a new Place instance.
  const place = new Place({
      id: 'ChIJB9a4Ifl744kRlpz0BQJzGQ8', // Crazy Good Kitchen
  });

  // Call fetchFields, passing the desired data fields.
  await place.fetchFields({
      fields: ["displayName", "formattedAddress", "location", "reviews"],
  });

  // Check for any place attributions.
  if (!place.attributions) {
      console.log('No attributions were found.');
      return;
  } else {
      // Log the place attribution
      for (var attribution of place.attributions) {
          console.log(attribution);
      }
  }

  
```

### Display a review

A `Place` object can contain up to five reviews, where each review is represented by a
`Review` object. You can optionally display these reviews in your app.

When displaying reviews contributed by Google users, you must place the author's name in close
proximity. When available in the author attribution field of the `Review` object, we
recommend you include the author's photo and link to their profile as well. The following image
shows an example of a review of a park:
![Author attribution display](https://developers.google.com/static/maps/documentation/places/images/review_attributions.png)

The following example shows getting a place, checking for reviews, and showing the data from
the first review:

```javascript
// Create a new Place instance.
const place = new Place({
    id: 'ChIJpyiwa4Zw44kRBQSGWKv4wgA', // Faneuil Hall Marketplace, Boston, MA
});

// Call fetchFields, passing 'reviews' and other needed fields.
await place.fetchFields({
    fields: ['displayName', 'formattedAddress', 'location', 'reviews'],
});

// Create an HTML container.
const content = document.createElement('div');
const title = document.createElement('div');
const rating = document.createElement('div');
const address = document.createElement('div');
const review = document.createElement('div');
const authorLink = document.createElement('a');

// If there are any reviews display the first one.
if (place.reviews && place.reviews.length > 0) {
    // Get info for the first review.
    const reviewRating = place.reviews[0].rating;
    const reviewText = place.reviews[0].text;
    const authorName = place.reviews[0].authorAttribution.displayName;
    const authorUri = place.reviews[0].authorAttribution.uri;

    // Safely populate the HTML.
    title.textContent = place.displayName || '';
    address.textContent = place.formattedAddress || '';
    rating.textContent = `Rating: ${reviewRating} stars`;
    review.textContent = reviewText || '';
    authorLink.textContent = authorName;
    authorLink.href = authorUri || '';
    authorLink.target = '_blank';

    content.appendChild(title);
    content.appendChild(address);
    content.appendChild(rating);
    content.appendChild(review);
    content.appendChild(authorLink);
} else {
    content.textContent = `No reviews were found for ${place.displayName}.`;
}

// Create an infoWindow to display the review.
infoWindow = new InfoWindow({
    content,
    ariaLabel: place.displayName,
});
```

[See the documentation for place reviews.](https://developers.google.com/maps/documentation/javascript/place-reviews.md.txt)

### Display attributions for a photo

If your app displays photos, you must show author attributions for each photo that has them.
Details about the photo in a `Place` object of a response are contained in the
`photos` array. To add the `photos` array to the response, include the
`photos` data field in the request.

Each element of the photos array is an instance of `Photo`, which contains the
`authorAttributions` array, of type AuthorAttribution. The fields of the
`AuthorAttribution` object are strings containing the `displayName`,
`uri`, and `photoUri` of the attribution, or an empty string if there are no
attributions to display.

[See the documentation for place photos.](https://developers.google.com/maps/documentation/javascript/place-photos.md.txt)

### Search results attributions

In Europe, when using Google's unadulterated ranking, search products must have explainer text no
more than 1 click away that describes the main factors and the weighting of the main factors that
determine search results ranking. Explainer text:
> *Header:* About these results  
>
> *Body:* When you search for businesses or places near a location, Google Maps will show you local results. Several factors --- primarily relevance, distance and prominence --- are combined to help find the best results for your search.  
>
> *Button 1:* Learn more  
> *"Learn more" text should link to a [Help Center article](https://support.google.com/maps/answer/3092445?&ref_topic=3092444#zippy=%2Cwithin-google-maps%2Cother-google-products).*  
>
> *Button 2:* OK

### Autocomplete for end user addresses

When an end user uses Autocomplete functionality within your Customer Application to type
ahead a street address and that street address would have been completely and accurately provided
by that end user without Autocomplete, the end user's selected address is then
not subject to the Google Maps Content restrictions in your Google Maps Platform Agreement.
This exception applies only to the street address selected by the end user and solely for
that end user's specific transaction; it does not apply to the list of suggested addresses
provided by the Autocomplete functionality or to other Google Maps Content. This exception does
not apply to any POI or address lookup functionality offered by other Google Maps Platform
Services.
![Autocomplete end user address](https://developers.google.com/static/maps/documentation/places/images/autocomplete-end-user-address.png)

* In the previous image, the address list on the left is still subject to the restrictions on Google Maps Content. Once the end user selects their chosen address, that address is not subject to the restrictions on Google Maps Content solely for the purpose of that end user's applicable transaction. *

### AI-powered summaries

When you display AI-powered summaries in your app --- including place, area, and
review summaries --- you must do the following:

- Display the required attributions, reporting links, and reference links as defined below.
- End users must be able to read the full summary text as it is provided by Google Maps.

#### Display AI-powered summaries disclosure text

When displaying an AI-powered summary of any type, always include the localized
disclosure text (provided in the `disclosureText` field of the response body)
immediately below the summary. Never modify or augment the disclosure text
provided by the API.
![Disclosure for all AI-powered summaries types](https://developers.google.com/static/maps/documentation/images/summaries_disclosure_all.jpg) **Figure 1**: Disclosure text properly displayed below each of the three AI-powered summary types.

#### Place and area summary additional requirements

[Place](https://developers.google.com/maps/documentation/places/web-service/place-summaries.md.txt) and [area
summaries](https://developers.google.com/maps/documentation/places/web-service/area-summaries) displayed in
your app must be accompanied by the following text and required links:

| Text | Requirement |
|---|---|
| About this summary | Use the following link to "How Google sources and uses information in local listings": <https://support.google.com/local-listings/answer/9851099>. |
| Report summary | Use the link contained in the `flagContentUri` field of the response to enable reporting an issue to Google about the content of a summary. **Note:** AI-powered summaries provided through the Places API (New) are subject to Google's content and product policies wherever you are in the world. You are required to notify your end users that if they would like to report content that should be removed from Google's services under applicable laws, they should report it using the provided flag content URL (`flagContentUri`). |

![Disclosure for place and area summaries](https://developers.google.com/static/maps/documentation/images/summaries_place_area.jpg) **Figure 2**: AI-powered area summary shown with required associated links made available to end users using an overflow menu.

#### Review summary requirements

[Review summaries](https://developers.google.com/maps/documentation/places/web-service/review-summaries.md.txt)
displayed in your app must be accompanied by a heading with the text "Review
summary." Additionally, you must use the following text and required links:

| Text | Requirement |
|---|---|
| About this summary | Use the following link to "How Google sources and uses information in local listings": <https://support.google.com/local-listings/answer/9851099> |
| Report summary | Use the link contained in the `flagContentUri` field of the response. **Note:** AI-powered summaries provided through the Places API (New) are subject to Google's content and product policies wherever you are in the world. You are required to notify your end users that if they would like to report content that should be removed from Google's services under applicable laws, they should report it using the provided flag content URL (`flagContentUri`). |
| See reviews | Use the link contained in the `reviewSummary.reviewsUri` field of the response. |

![Disclosure for review summaries](https://developers.google.com/static/maps/documentation/images/summaries_review.jpg) **Figure 3**: AI-powered review summary shown with required associated links made available to end users using an overflow menu.

#### Display guidance for automotive use cases

For driver safety, Google recommends rendering AI-powered summaries in parked
mode for automotive experiences. If rendering summaries in driving mode,
on-screen information should be simple, clear, and concise to ensure that the
driver's attention returns quickly to the road:

- No more than 3 lines
- 120 characters or 24 words or less
- Minimum front size of 24dp

Especially in automotive contexts, it's the developer's responsibility to render
AI-powered summaries in ways that are safe and compliant with all local laws and
regulations.