<!--
{
  "availability" : [
    "macOS: 10.8.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "AppKit",
  "identifier" : "/documentation/AppKit/NSDocument/isDraft",
  "metadataVersion" : "0.1.0",
  "role" : "Instance Property",
  "symbol" : {
    "kind" : "Instance Property",
    "modules" : [
      "AppKit"
    ],
    "preciseIdentifier" : "c:objc(cs)NSDocument(py)draft"
  },
  "title" : "isDraft"
}
-->

# isDraft

A Boolean value that indicates whether the document is a draft that the user has not yet saved.

```
nonisolated var isDraft: Bool { get set }
```

## Discussion

The system presents a Save dialog when the user closes a draft document. Only documents with non-`nil` values for the [`fileURL`](/documentation/AppKit/NSDocument/fileURL) property should be considered drafts.

---

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)