<!--
{
  "availability" : [
    "macOS: -"
  ],
  "documentType" : "symbol",
  "framework" : "AppKit",
  "identifier" : "/documentation/AppKit/NSPasteboard/ReadingOptionKey",
  "metadataVersion" : "0.1.0",
  "role" : "Structure",
  "symbol" : {
    "kind" : "Structure",
    "modules" : [
      "AppKit"
    ],
    "preciseIdentifier" : "c:@T@NSPasteboardReadingOptionKey"
  },
  "title" : "NSPasteboard.ReadingOptionKey"
}
-->

# NSPasteboard.ReadingOptionKey

Options for reading pasteboard data.

```
struct ReadingOptionKey
```

## Discussion

These options can be used for both the [`readObjects(forClasses:options:)`](/documentation/AppKit/NSPasteboard/readObjects(forClasses:options:)) and [`canReadObject(forClasses:options:)`](/documentation/AppKit/NSPasteboard/canReadObject(forClasses:options:)) methods, unless otherwise specified.  The currently available options allow for customization of how URLS are read from the pasteboard.

## Topics

### Type Properties

[`static let urlReadingContentsConformToTypes: NSPasteboard.ReadingOptionKey`](/documentation/AppKit/NSPasteboard/ReadingOptionKey/urlReadingContentsConformToTypes)

Option for reading URLs to restrict the results to URLs with contents that conform to any of the provided UTI types.

[`static let urlReadingFileURLsOnly: NSPasteboard.ReadingOptionKey`](/documentation/AppKit/NSPasteboard/ReadingOptionKey/urlReadingFileURLsOnly)

Option for reading URLs to restrict the results to file URLs only.

### Initializers

[`init(rawValue: String)`](/documentation/AppKit/NSPasteboard/ReadingOptionKey/init(rawValue:))

## Relationships

### Conforms To

[`Equatable`](/documentation/Swift/Equatable)

[`RawRepresentable`](/documentation/Swift/RawRepresentable)

[`Sendable`](/documentation/Swift/Sendable)

[`Hashable`](/documentation/Swift/Hashable)

[`SendableMetatype`](/documentation/Swift/SendableMetatype)

---

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)