---
title: "downloadWindow(forAuthenticationSheet:)"
framework: webkit
role: symbol
role_heading: Instance Method
path: "webkit/webdownloaddelegate/downloadwindow(forauthenticationsheet:)"
---

# downloadWindow(forAuthenticationSheet:)

Returns the window to be used by the authentication sheet.

## Declaration

```swift
optional func downloadWindow(forAuthenticationSheet download: WebDownload!) -> NSWindow!
```

## Parameters

- `download`: The download object that is requesting the window.

## Return Value

Return Value An NSWindow object into which the WebDownload object should draw its authentication sheet.

## Discussion

Discussion The default implementation prompts the user for authentication using the standard WebKit authentication panel, as either a sheet or window.
