---
title: fileURL
framework: appkit
role: symbol
role_heading: Instance Property
path: appkit/nsdocument/fileurl
---

# fileURL

The location of the document’s on-disk representation.

## Declaration

```swift
nonisolated var fileURL: URL? { get set }
```

## Return Value

Return Value The document’s location.

## Discussion

Discussion The default implementation of this property returns the URL of the file that was opened. Changing the value of this property does not actually change the document’s name or location; it is only for recording the document’s location during its initial opening or saving.

## See Also

### Getting Document Metadata

- [isEntireFileLoaded](appkit/nsdocument/isentirefileloaded.md)
- [fileModificationDate](appkit/nsdocument/filemodificationdate.md)
- [keepBackupFile](appkit/nsdocument/keepbackupfile.md)
- [isDraft](appkit/nsdocument/isdraft.md)
- [fileType](appkit/nsdocument/filetype.md)
- [isDocumentEdited](appkit/nsdocument/isdocumentedited.md)
- [isInViewingMode](appkit/nsdocument/isinviewingmode.md)
