<!--
{
  "availability" : [
    "iOS: 8.0.0 -",
    "iPadOS: 8.0.0 -",
    "macCatalyst: 13.1.0 -",
    "macOS: 10.13.0 -",
    "tvOS: 10.0.0 -",
    "visionOS: 1.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "PhotoKit",
  "identifier" : "/documentation/Photos/PHAssetImageProgressHandler",
  "metadataVersion" : "0.1.0",
  "role" : "Type Alias",
  "symbol" : {
    "kind" : "Type Alias",
    "modules" : [
      "Photos"
    ],
    "preciseIdentifier" : "c:@T@PHAssetImageProgressHandler"
  },
  "title" : "PHAssetImageProgressHandler"
}
-->

# PHAssetImageProgressHandler

The signature for a block that Photos calls while downloading asset data from iCloud. Used by the [`progressHandler`](/documentation/Photos/PHImageRequestOptions/progressHandler) property.

```
typealias PHAssetImageProgressHandler = (Double, (any Error)?, UnsafeMutablePointer<ObjCBool>, [AnyHashable : Any]?) -> Void
```

## Discussion

If you request an image whose data is not on the local device, and you have enabled downloading with the [`isNetworkAccessAllowed`](/documentation/Photos/PHImageRequestOptions/isNetworkAccessAllowed) property, Photos calls your block periodically to report progress and to allow you to cancel the download.

> Note:
> Photos calls this block in an arbitrary serial queue. Dispatch to the main thread if your handler needs to update the user interface.

The block takes the following parameters:

- progress: A floating-point value indicating the progress of the download. A value of `0.0` indicates that the download has just started, and a value of `1.0` indicates the download is complete.
- error: An `NSError` object describing an error that occurred when attempting to download the image, or `nil` if no errors have occurred.
- stop: A pointer to a Boolean value. To cancel the download, set `*stop` to `true` inside the block.
- info: A dictionary providing additional information about the status of the image request. See Image Result Info Keys for possible keys and values. For example, a `true` value for the key [`PHImageResultIsDegradedKey`](/documentation/Photos/PHImageResultIsDegradedKey) indicates that Photos may send the full-quality version of the image later, depending on the value of the image request’s [`deliveryMode`](/documentation/Photos/PHImageRequestOptions/deliveryMode) property.

---

Copyright &copy; 2026 Apple Inc. All rights reserved. | [Terms of Use](https://www.apple.com/legal/internet-services/terms/site.html) | [Privacy Policy](https://www.apple.com/privacy/privacy-policy)