<!--
{
  "availability" : [
    "iOS: -",
    "iPadOS: -",
    "visionOS: 2.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "QuickLook",
  "identifier" : "/documentation/QuickLook/PreviewApplication/open(items:selectedItem:)",
  "metadataVersion" : "0.1.0",
  "role" : "Type Method",
  "symbol" : {
    "kind" : "Type Method",
    "modules" : [
      "Quick Look"
    ],
    "preciseIdentifier" : "s:9QuickLook18PreviewApplicationC4open5items12selectedItemAA0C7SessionVSayAA0cH0VG_AJSgtFZ"
  },
  "title" : "open(items:selectedItem:)"
}
-->

# open(items:selectedItem:)

Previews the provided items.

```
final class func open(items: [PreviewItem], selectedItem: PreviewItem? = nil) -> PreviewSession
```

## Parameters

`items`

An array of preview items to present in the new `PreviewApplication` scene.

`selectedItem`

If provided and in the array of passed items, the preview item to select in the presented collection..

## Return Value

A `PreviewSession` instance.

## Discussion

This method launches the preview application with the provided preview items and, optionally, a selected item.

---

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)