---
title: parent
framework: uikit
role: symbol
role_heading: Instance Property
path: uikit/uiviewcontroller/parent
---

# parent

The parent view controller of the recipient.

## Declaration

```swift
weak var parent: UIViewController? { get }
```

## Discussion

Discussion If the recipient is a child of a container view controller, this property holds the view controller it is contained in. If the recipient has no parent, the value in this property is nil. Prior to iOS 5.0, if a view did not have a parent view controller and was being presented, the presenting view controller would be returned. On iOS 5, this behavior no longer occurs. Instead, use the presentingViewController property to access the presenting view controller.

## See Also

### Getting other related view controllers

- [presentingViewController](uikit/uiviewcontroller/presentingviewcontroller.md)
- [presentedViewController](uikit/uiviewcontroller/presentedviewcontroller.md)
- [splitViewController](uikit/uiviewcontroller/splitviewcontroller.md)
- [navigationController](uikit/uiviewcontroller/navigationcontroller.md)
- [tabBarController](uikit/uiviewcontroller/tabbarcontroller.md)
