<!--
{
  "availability" : [
    "iOS: 14.5.0 -",
    "iPadOS: 14.5.0 -",
    "macCatalyst: 14.5.0 -",
    "macOS: 11.3.0 -",
    "visionOS: 1.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "WebKit",
  "identifier" : "/documentation/WebKit/WKDownload",
  "metadataVersion" : "0.1.0",
  "role" : "Class",
  "symbol" : {
    "kind" : "Class",
    "modules" : [
      "WebKit"
    ],
    "preciseIdentifier" : "c:objc(cs)WKDownload"
  },
  "title" : "WKDownload"
}
-->

# WKDownload

An object that represents the download of a web resource.

```
@MainActor class WKDownload
```

## Topics

### Managing the download

[`var delegate: (any WKDownloadDelegate)?`](/documentation/WebKit/WKDownload/delegate)

An object you use to track download progress and handle redirects, authentication challenges, and failures.

[`func cancel(((Data?) -> Void)?)`](/documentation/WebKit/WKDownload/cancel(_:))

Cancels the download, and optionally captures data so that you can resume the download later.

[`enum RedirectPolicy`](/documentation/WebKit/WKDownload/RedirectPolicy)

An enumeration with cases that indicate whether to proceed with a redirect.

### Inspecting the download

[`var originalRequest: URLRequest?`](/documentation/WebKit/WKDownload/originalRequest)

An object that represents the request that initiated the download.

[`var webView: WKWebView?`](/documentation/WebKit/WKDownload/webView)

The web view where the download initiated.

### Instance Properties

[`var isUserInitiated: Bool`](/documentation/WebKit/WKDownload/isUserInitiated)

[`var originatingFrame: WKFrameInfo`](/documentation/WebKit/WKDownload/originatingFrame)

## Relationships

### Conforms To

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

[`ProgressReporting`](/documentation/Foundation/ProgressReporting)

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

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

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

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

[`NSObjectProtocol`](/documentation/ObjectiveC/NSObjectProtocol)

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

### Inherits From

[`NSObject-swift.class`](/documentation/ObjectiveC/NSObject-swift.class)

---

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)