---
title: "locationManager(_:didUpdateLocations:)"
framework: corelocation
role: symbol
role_heading: Instance Method
path: "corelocation/cllocationmanagerdelegate/locationmanager(_:didupdatelocations:)"
---

# locationManager(_:didUpdateLocations:)

Tells the delegate that new location data is available.

## Declaration

```swift
optional func locationManager(_ manager: CLLocationManager, didUpdateLocations locations: [CLLocation])
```

## Parameters

- `manager`: The location manager object that generated the update event.
- `locations`: An array of doc://com.apple.corelocation/documentation/CoreLocation/CLLocation objects containing the location data. This array always contains at least one object representing the current location. If updates were deferred or if multiple locations arrived before they could be delivered, the array may contain additional entries. The objects in the array are organized in the order in which they occurred. Therefore, the most recent location update is at the end of the array.

## Discussion

Discussion Implementation of this method is optional but recommended.

## Topics

### Related Documentation

- [MapKit](mapkit.md)
- [MapKit JS](mapkitjs.md)

## See Also

### Receiving location updates

- [locationManager(_:didUpdateTo:from:)](corelocation/cllocationmanagerdelegate/locationmanager(_:didupdateto:from:).md)
- [locationManager(_:didFinishDeferredUpdatesWithError:)](corelocation/cllocationmanagerdelegate/locationmanager(_:didfinishdeferredupdateswitherror:).md)
