---
title: "mapView(_:didSelect:)"
framework: mapkit
role: symbol
role_heading: Instance Method
path: "mapkit/mkmapviewdelegate/mapview(_:didselect:)-9km43"
---

# mapView(_:didSelect:)

Tells the delegate when the user selects one or more annotations.

## Declaration

```swift
optional func mapView(_ mapView: MKMapView, didSelect annotation: any MKAnnotation)
```

## Parameters

- `mapView`: The map view containing the annotation view.
- `annotation`: The selected annotation view.

## See Also

### Selecting annotations and annotations views

- [mapView(_:didSelect:)](mapkit/mkmapviewdelegate/mapview(_:didselect:)-41by3.md)
- [mapView(_:didDeselect:)](mapkit/mkmapviewdelegate/mapview(_:diddeselect:)-yo7q.md)
- [mapView(_:didDeselect:)](mapkit/mkmapviewdelegate/mapview(_:diddeselect:)-4ldss.md)
- [selectableMapFeatures](mapkit/mkmapview/selectablemapfeatures.md)
