<!--
{
  "availability" : [
    "macCatalyst: -",
    "macOS: 10.0.0 - 10.14.0"
  ],
  "documentType" : "symbol",
  "framework" : "AppKit",
  "identifier" : "/documentation/AppKit/NSURLPboardType",
  "metadataVersion" : "0.1.0",
  "role" : "Global Variable",
  "symbol" : {
    "kind" : "Global Variable",
    "modules" : [
      "AppKit"
    ],
    "preciseIdentifier" : "c:@NSURLPboardType"
  },
  "title" : "NSURLPboardType"
}
-->

# NSURLPboardType

`NSURL` data for one file or resource.

```
extern NSPasteboardType NSURLPboardType;
```

## Discussion

In macOS 10.6 and later, use [`writeObjects(_:)`](/documentation/AppKit/NSPasteboard/writeObjects(_:)) to write URLs directly to the pasteboard instead.

In OS X v10.5 and earlier: to write an URL to a pasteboard you use <doc://com.apple.documentation/documentation/Foundation/NSURL/write(to:)> (<doc://com.apple.documentation/documentation/Foundation/NSURL>); to get an URL from a pasteboard you use <doc://com.apple.documentation/documentation/Foundation/NSURL/init(fromPasteboard:)> (<doc://com.apple.documentation/documentation/Foundation/NSURL>).

---

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)