---
title: duration
framework: avfoundation
role: symbol
role_heading: Type Property
path: avfoundation/avpartialasyncproperty/duration
---

# duration

A time value that represents the duration of the asset.

## Declaration

```swift
static var duration: AVAsyncProperty<Root, CMTime> { get }
```

## Discussion

Discussion Use the load(_:isolation:) method to retrieve the property value. If the value of providesPreciseDurationAndTiming is false, the asset returns a best-available estimate of the duration. You can specify your preferred degree of precision for timing-related properties when you create an AVURLAsset by passing a value for the AVURLAssetPreferPreciseDurationAndTimingKey initialization option.

## See Also

### Loading duration and timing

- [providesPreciseDurationAndTiming](avfoundation/avpartialasyncproperty/providesprecisedurationandtiming.md)
- [minimumTimeOffsetFromLive](avfoundation/avpartialasyncproperty/minimumtimeoffsetfromlive.md)
