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

# removeWindowsItem(_:)

Removes the Window menu item for a given window.

```
func removeWindowsItem(_ win: NSWindow)
```

## Parameters

`win`

The window whose menu item is to be removed.

## Discussion

This method doesn’t prevent the item from being automatically added again. Use the [`isExcludedFromWindowsMenu`](/documentation/AppKit/NSWindow/isExcludedFromWindowsMenu) method of [`NSWindow`](/documentation/AppKit/NSWindow) if you want the item to remain excluded from the Window menu.

---

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)