Search code examples
javascripthtmlgoogle-mapsgoogle-maps-api-3markerclusterer

How can I cluster markers without overlap with google maps?


I am currently clustering hundreds of markers on my google maps. Many of the markers are based on geo-coded addresses, which at times only resolve to the city level. Normally i will end up with lets say a few hundred addresses all with the same lat lon for example in the middle of New York City.

I know about the Marker Clustering in google maps, however when all the markers have the same lat long, you loose the ability to click on each marker, and bring up a popup.

How can I manage these markers in such a way when you zoom in you can still tell how many markers there are, and still click on them?


Solution

  • Look at the OverlappingMarkerSpiderfier

    See this post on integrating it with MarkerClusterer