---
title: "removeLayoutGuide(_:)"
framework: appkit
role: symbol
role_heading: Instance Method
path: "appkit/nsview/removelayoutguide(_:)"
---

# removeLayoutGuide(_:)

Removes the provided layout guide from the view.

## Declaration

```swift
func removeLayoutGuide(_ guide: NSLayoutGuide)
```

## Parameters

- `guide`: The layout guide to be removed.

## Discussion

Discussion This method removes the provided layout guide from the view’s layoutGuides array. It also sets the guide’s owningView property to nil. Finally, it removes any constraints to the layout guide. Layout guides cannot participate in Auto Layout constraints unless they are added by a view in the view hierarchy.

## See Also

### Managing Layout Guides

- [addLayoutGuide(_:)](appkit/nsview/addlayoutguide(_:).md)
- [layoutGuides](appkit/nsview/layoutguides.md)
- [layoutMarginsGuide](appkit/nsview/layoutmarginsguide.md)
