---
title: representedURL
framework: appkit
role: symbol
role_heading: Instance Property
path: appkit/nswindow/representedurl
---

# representedURL

The URL of the file the window represents.

## Declaration

```swift
var representedURL: URL? { get set }
```

## Discussion

Discussion When the URL specifies a path, the window shows an icon in its title bar, as described in the following table:  |   |   |   |  You can customize the file icon in the title bar with the following code: [[<window> standardWindowButton:NSWindowDocumentIconButton] setImage:<image>] When the URL identifies an existing file, the window’s title offers a pop-up menu showing the path components of the URL. (The user displays this menu by Command-clicking the title.) The behavior and contents of this menu can be controlled with window(_:shouldPopUpDocumentPathMenu:).

## See Also

### Related Documentation

- [window(_:shouldDragDocumentWith:from:with:)](appkit/nswindowdelegate/window(_:shoulddragdocumentwith:from:with:).md)

### Managing Titles

- [title](appkit/nswindow/title.md)
- [subtitle](appkit/nswindow/subtitle.md)
- [titleVisibility](appkit/nswindow/titlevisibility-swift.property.md)
- [setTitleWithRepresentedFilename(_:)](appkit/nswindow/settitlewithrepresentedfilename(_:).md)
- [representedFilename](appkit/nswindow/representedfilename.md)
