---
title: nextKeyView
framework: appkit
role: symbol
role_heading: Instance Property
path: appkit/nsview/nextkeyview
---

# nextKeyView

The view object that follows the current view in the key view loop.

## Declaration

```swift
unowned(unsafe) var nextKeyView: NSView? { get set }
```

## Discussion

Discussion The value in this property is nil if there is no next view in the key view loop. You can assign a view to this property to make that view the next view in the loop. The view in this property should, if possible, be made first responder when the user navigates forward from the view using keyboard interface control.

## See Also

### Related Documentation

- [selectKeyView(following:)](appkit/nswindow/selectkeyview(following:).md)
- [selectNextKeyView(_:)](appkit/nswindow/selectnextkeyview(_:).md)
- [selectPreviousKeyView(_:)](appkit/nswindow/selectpreviouskeyview(_:).md)
- [selectKeyView(preceding:)](appkit/nswindow/selectkeyview(preceding:).md)

### Managing the Key-View Loop

- [canBecomeKeyView](appkit/nsview/canbecomekeyview.md)
- [needsPanelToBecomeKey](appkit/nsview/needspaneltobecomekey.md)
- [nextValidKeyView](appkit/nsview/nextvalidkeyview.md)
- [previousKeyView](appkit/nsview/previouskeyview.md)
- [previousValidKeyView](appkit/nsview/previousvalidkeyview.md)
