---
title: clusteringIdentifier
framework: mapkit
role: symbol
role_heading: Instance Property
path: mapkit/mkannotationview/clusteringidentifier
---

# clusteringIdentifier

An identifier that determines whether the annotation view participates in clustering.

## Declaration

```swift
var clusteringIdentifier: String? { get set }
```

## Discussion

Discussion The default value of this property is nil, which prevents MapKit from clustering the annotation view with other annotation views. Setting the property to a non-nil value enables it to participate in clustering. Clustering occurs when there’s a collision between multiple annotation views with the same identifier on the map surface. MapKit removes the annotation views involved in the collision from the map view and replaces them with a clustering annotation view, which displays the title from one of the annotations and provides access to the other annotations.

## See Also

### Clustering annotation views

- [Decluttering a Map with MapKit Annotation Clustering](mapkit/decluttering-a-map-with-mapkit-annotation-clustering.md)
- [cluster](mapkit/mkannotationview/cluster.md)
