<!--
{
  "availability" : [
    "iOS: -",
    "iPadOS: -",
    "macCatalyst: -",
    "visionOS: -"
  ],
  "documentType" : "symbol",
  "framework" : "UIKit",
  "identifier" : "/documentation/UIKit/UIImagePickerControllerDelegate",
  "metadataVersion" : "0.1.0",
  "role" : "Protocol",
  "symbol" : {
    "kind" : "Protocol",
    "modules" : [
      "UIKit"
    ],
    "preciseIdentifier" : "c:objc(pl)UIImagePickerControllerDelegate"
  },
  "title" : "UIImagePickerControllerDelegate"
}
-->

# UIImagePickerControllerDelegate

A set of methods that your delegate object must implement to interact with the image picker interface.

```
@MainActor protocol UIImagePickerControllerDelegate : NSObjectProtocol
```

## Overview

The methods of this protocol notify your delegate when the user either picks an image or movie, or cancels the picker operation. The delegate methods are responsible for dismissing the picker when the operation completes. To dismiss the picker, call the [`dismiss(animated:completion:)`](/documentation/UIKit/UIViewController/dismiss(animated:completion:)) method of the parent controller responsible for displaying the [`UIImagePickerController`](/documentation/UIKit/UIImagePickerController) object.

To save a still image to the user’s Camera Roll album, call the [`UIImageWriteToSavedPhotosAlbum(_:_:_:_:)`](/documentation/UIKit/UIImageWriteToSavedPhotosAlbum(_:_:_:_:)) function from within the body of the [`imagePickerController(_:didFinishPickingMediaWithInfo:)`](/documentation/UIKit/UIImagePickerControllerDelegate/imagePickerController(_:didFinishPickingMediaWithInfo:)) method. To save a movie to the user’s Camera Roll album, instead call the [`UISaveVideoAtPathToSavedPhotosAlbum(_:_:_:_:)`](/documentation/UIKit/UISaveVideoAtPathToSavedPhotosAlbum(_:_:_:_:)) function. These functions, described in `UIKit Functions`, save the image or movie only; they don’t save metadata.

To write additional metadata when saving an image to the Camera Roll, use the <doc://com.apple.documentation/documentation/Photos/PHAssetChangeRequest> class from the Photos framework. See the description for the [`mediaMetadata`](/documentation/UIKit/UIImagePickerController/InfoKey/mediaMetadata) key.

## Topics

### Closing the picker

[`imagePickerController(_:didFinishPickingMediaWithInfo:)`](/documentation/UIKit/UIImagePickerControllerDelegate/imagePickerController(_:didFinishPickingMediaWithInfo:))

Tells the delegate that the user picked a still image or movie.

[`imagePickerControllerDidCancel(_:)`](/documentation/UIKit/UIImagePickerControllerDelegate/imagePickerControllerDidCancel(_:))

Tells the delegate that the user canceled the pick operation.

[`imagePickerController:didFinishPickingImage:editingInfo:`](/documentation/UIKit/UIImagePickerControllerDelegate/imagePickerController:didFinishPickingImage:editingInfo:)

Tells the delegate that the user picked an image.

### Getting the editing information

[`UIImagePickerController.InfoKey`](/documentation/UIKit/UIImagePickerController/InfoKey)

Keys you use to retrieve information from the editing dictionary about the media that the user selected.



---

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)