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

# modalWindow

The modal window displayed by the app.

```
var modalWindow: NSWindow? { get }
```

## Discussion

This property contains the current standalone modal window or `nil` if no modal window is being displayed. This property does not contain sheets that are attached to other windows. To retrieve a sheet, use the [`attachedSheet`](/documentation/AppKit/NSWindow/attachedSheet) method of [`NSWindow`](/documentation/AppKit/NSWindow).

---

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)