<!--
{
  "availability" : [
    "iOS: 9.1.0 -",
    "iPadOS: 9.1.0 -",
    "macCatalyst: 13.1.0 -",
    "macOS: 10.12.0 -",
    "tvOS: 10.0.0 -",
    "visionOS: 1.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "PhotoKit",
  "identifier" : "/documentation/PhotosUI/PHLivePhotoView",
  "metadataVersion" : "0.1.0",
  "role" : "Class",
  "symbol" : {
    "kind" : "Class",
    "modules" : [
      "PhotosUI"
    ],
    "preciseIdentifier" : "c:objc(cs)PHLivePhotoView"
  },
  "title" : "PHLivePhotoView"
}
-->

# PHLivePhotoView

A view that displays a Live Photo—a picture that also includes motion and sound from the moments just before and after its capture.

```
class PHLivePhotoView
```

## Overview

Use a Live Photo view to display the photo and control playback of its motion and sound content. In iOS and tvOS, you can obtain Live Photo objects from the Photos library, using the [`PHPickerViewController`](/documentation/PhotosUI/PHPickerViewController) or [`PHAsset`](/documentation/Photos/PHAsset) and [`PHImageManager`](/documentation/Photos/PHImageManager) classes, or by creating one from asset resources exported from a Photos library. In macOS, Live Photo objects are available only when editing Live Photo content in a photo editing extension that runs in the Photos app—see the [`PHContentEditingInput`](/documentation/Photos/PHContentEditingInput) class to access Live Photo content in an editing session.

By default, a Live Photo view uses its own gesture recognizer to allow the user to play the motion and sound content of a Live Photo with the same interactions and visual effects seen in the Photos app. To customize this gesture recognizer—for example, to install it on a different view for proper event handling in your app’s view hierarchy—use the [`playbackGestureRecognizer`](/documentation/PhotosUI/PHLivePhotoView/playbackGestureRecognizer) property.

To animate the view briefly to hint that a picture is a Live Photo, use the [`startPlayback(with:)`](/documentation/PhotosUI/PHLivePhotoView/startPlayback(with:)) method with the [`PHLivePhotoViewPlaybackStyle.hint`](/documentation/PhotosUI/PHLivePhotoViewPlaybackStyle/hint) option.

> Tip:
> This class displays Live Photos in native iOS and tvOS apps and macOS photo editing extensions. To display Live Photo content on the web, use the <doc://com.apple.documentation/documentation/LivePhotosKitJS> framework.

## Topics

### Choosing a Live Photo to Display

[`livePhoto`](/documentation/PhotosUI/PHLivePhotoView/livePhoto)

The Live Photo displayed in the view.

### Managing Playback

[`playbackGestureRecognizer`](/documentation/PhotosUI/PHLivePhotoView/playbackGestureRecognizer)

A gesture recognizer that controls playback of the Live Photo in the view.

[`isMuted`](/documentation/PhotosUI/PHLivePhotoView/isMuted)

A Boolean value that determines whether the view plays the audio content of its Live Photo.

[`audioVolume`](/documentation/PhotosUI/PHLivePhotoView/audioVolume)

The audio gain to apply to the Live Photo’s movie content during playback.

### Responding to Playback Events

[`delegate`](/documentation/PhotosUI/PHLivePhotoView/delegate)

An object to be notified when Live Photo playback begins or ends.

[`PHLivePhotoViewDelegate`](/documentation/PhotosUI/PHLivePhotoViewDelegate)

The [`PHLivePhotoViewDelegate`](/documentation/PhotosUI/PHLivePhotoViewDelegate) protocol describes messages sent by a [`PHLivePhotoView`](/documentation/PhotosUI/PHLivePhotoView) instance in response to playback events when playing the motion and sound content associated with a Live Photo. To receive these messages, implement the methods in this protocol in one of your controller objects and assign that object to the [`delegate`](/documentation/PhotosUI/PHLivePhotoView/delegate) property of a Live Photo view.

### Manually Playing Live Photo Content

[`startPlayback(with:)`](/documentation/PhotosUI/PHLivePhotoView/startPlayback(with:))

Begins playback of Live Photo content in the view.

[`stopPlayback()`](/documentation/PhotosUI/PHLivePhotoView/stopPlayback())

Stops playback of a Live Photo.

[`stopPlayback(animated:)`](/documentation/PhotosUI/PHLivePhotoView/stopPlayback(animated:))

Stops playback of a Live Photo in an animated manner.

### Accessing User Interface Icons for Live Photos

[`livePhotoBadgeImage(options:)`](/documentation/PhotosUI/PHLivePhotoView/livePhotoBadgeImage(options:))

Returns an icon image for the specified Live Photo semantic options.

[`livePhotoBadgeView`](/documentation/PhotosUI/PHLivePhotoView/livePhotoBadgeView)

A view for displaying Live Photo status.

### Setting the Content Mode

[`contentMode`](/documentation/PhotosUI/PHLivePhotoView/contentMode)

The mode in which the view displays its content.

[`PHLivePhotoViewContentMode`](/documentation/PhotosUI/PHLivePhotoViewContentMode)

The enumerated Live Photo content modes.

### Constants

[`PHLivePhotoViewPlaybackStyle`](/documentation/PhotosUI/PHLivePhotoViewPlaybackStyle)

Options for how much of the motion and sound content of a Live Photo to play, used in the [`startPlayback(with:)`](/documentation/PhotosUI/PHLivePhotoView/startPlayback(with:)) method and in messages to the view’s [`delegate`](/documentation/PhotosUI/PHLivePhotoView/delegate) object.

[`PHLivePhotoBadgeOptions`](/documentation/PhotosUI/PHLivePhotoBadgeOptions)

Options for the semantic use and display style of icons for badging Live Photo assets, used by the [`livePhotoBadgeImage(options:)`](/documentation/PhotosUI/PHLivePhotoView/livePhotoBadgeImage(options:)) method.



---

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)