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

# delegate

The object you use to customize the toolbar contents and configuration.

```
weak var delegate: (any NSToolbarDelegate)? { get set }
```

## Discussion

Assign an object to this property if you customize the toolbar’s behavior. The object you assign to this property must adopt the [`NSToolbarDelegate`](/documentation/AppKit/NSToolbarDelegate) protocol.

---

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)