Businesses and Other Points of Interest

  • Points of Interest (POIs) such as parks, schools, and businesses, are displayed on the map by default with corresponding icons.

  • Developers can listen for click events on POIs and respond to user interactions using the OnPoiClickListener.

  • Although POIs are displayed by default, there is no default on-click UI, meaning developers need to implement their own info windows or other UI elements.

  • The display of POIs can be customized or hidden altogether using JSON style declarations to control their visibility and appearance.

Select platform: Android iOS JavaScript

By default, points of interest (POIs) appear on the base map along with their corresponding icons. POIs include parks, schools, government buildings, and more.

In addition, business POIs appear by default on the map when the map type is normal. Business POIs represent businesses such as shops, restaurants, hotels, and more. Business POIs on indoor maps (floor plans) appear only on a lite mode map.

A POI corresponds to a Place ID, as defined in the Places SDK for Android. For example, recreational parks are POIs, but things like water fountains are generally not POIs (unless they're of national or historic significance).

Listen for click events on POIs

If you want to respond to a user tapping on a POI, you can use an OnPoiClickListener as shown in the following code sample:

Kotlin

internalclassOnPoiClickDemoActivity:AppCompatActivity(),OnMapReadyCallback,OnPoiClickListener{
overridefunonCreate(savedInstanceState:Bundle?){
super.onCreate(savedInstanceState)
setContentView(R.layout.poi_click_demo)
valmapFragment=supportFragmentManager.findFragmentById(R.id.map)
asSupportMapFragment
mapFragment.getMapAsync(this)
}
overridefunonMapReady(map:GoogleMap){
map.setOnPoiClickListener(this)
}
overridefunonPoiClick(poi:PointOfInterest){
Toast.makeText(this,"""Clicked: ${poi.name}
 Place ID:${poi.placeId}
 Latitude:${poi.latLng.latitude} Longitude:${poi.latLng.longitude}""",
Toast.LENGTH_SHORT
).show()
}
}

Java

class OnPoiClickDemoActivityextendsAppCompatActivityimplements
OnMapReadyCallback,GoogleMap.OnPoiClickListener{
@Override
protectedvoidonCreate(BundlesavedInstanceState){
super.onCreate(savedInstanceState);
setContentView(R.layout.poi_click_demo);
SupportMapFragmentmapFragment;
mapFragment=(SupportMapFragment)getSupportFragmentManager().findFragmentById(R.id.map);
mapFragment.getMapAsync(this);
}
@Override
publicvoidonMapReady(GoogleMapmap){
map.setOnPoiClickListener(this);
}
@Override
publicvoidonPoiClick(PointOfInterestpoi){
Toast.makeText(this,"Clicked: "+
poi.name+"\nPlace ID:"+poi.placeId+
"\nLatitude:"+poi.latLng.latitude+
" Longitude:"+poi.latLng.longitude,
Toast.LENGTH_SHORT).show();
}
}

POIs appear on the map by default, but there is no default on-click UI. That is, the API does not automatically display an info window or any other user interface when the user taps a POI.

As the above sample shows, you set the OnPoiClickListener on the map by calling GoogleMap.setOnPoiClickListener(OnPoiClickListener). When a user clicks (taps) on a POI, your app receives an OnPoiClick(PointOfInterest) event indicating the point of interest (POI) that the user clicked. The PointOfInterest contains the latitude/longitude coordinates, place ID and name of the point of interest.

Stop POIs from showing on the map

You can hide points of interest (POIs) by applying custom styles to all POIs or to specific categories of POIs.

The following JSON style declaration hides all business POIs on the map:

[
 {
 "featureType": "poi.business",
 "stylers": [
 { "visibility": "off" }
 ]
 }
]

As another example, the following JSON simplifies the display of all categories of POIs:

[
{
"featureType":"poi",
"stylers":[
{"visibility":"simplified"}
]
}
]

For Java code and other details, see the guide to hiding map features with styling.

Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License, and code samples are licensed under the Apache 2.0 License. For details, see the Google Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates.

Last updated 2026年09月01日 UTC.