---
title: owningView
framework: appkit
role: symbol
role_heading: Instance Property
path: appkit/nslayoutguide/owningview
---

# owningView

The view that owns this layout guide.

## Declaration

```swift
weak var owningView: NSView? { get set }
```

## Discussion

Discussion By default, this property is nil.  To participate in Auto Layout, the layout guide must be added to a view by calling its addLayoutGuide(_:) method. Do not modify this property directly. Instead, use the view’s addLayoutGuide(_:) and removeLayoutGuide(_:) methods, which update this property as necessary.

## See Also

### Working With Layout Guides

- [identifier](appkit/nslayoutguide/identifier.md)
- [frame](appkit/nslayoutguide/frame.md)
