<!--
{
  "availability" : [
    "iOS: 8.0.0 -",
    "iPadOS: 8.0.0 -",
    "macCatalyst: 13.1.0 -",
    "tvOS: -",
    "visionOS: 1.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "UIKit",
  "identifier" : "/documentation/UIKit/UIPresentationController/init(presentedViewController:presenting:)",
  "metadataVersion" : "0.1.0",
  "role" : "Initializer",
  "symbol" : {
    "kind" : "Initializer",
    "modules" : [
      "UIKit"
    ],
    "preciseIdentifier" : "c:objc(cs)UIPresentationController(im)initWithPresentedViewController:presentingViewController:"
  },
  "title" : "init(presentedViewController:presenting:)"
}
-->

# init(presentedViewController:presenting:)

Initializes and returns a presentation controller for transitioning between the specified view controllers.

```
init(presentedViewController: UIViewController, presenting presentingViewController: UIViewController?)
```

## Parameters

`presentedViewController`

The view controller being presented modally.

`presentingViewController`

The view controller whose content represents the starting point of the transition.

## Return Value

An initialized presentation controller object or `nil` if the presentation controller could not be initialized.

## Discussion

This method is the designated initializer for the presentation controller. You must call it from any custom initialization methods you define for your presentation controller subclasses.

---

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)