<!--
{
  "availability" : [
    "iOS: -",
    "iPadOS: -",
    "visionOS: 2.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "AVKit",
  "identifier" : "/documentation/AVKit/AVExperienceController/Delegate-swift.protocol/experienceController(_:prepareForTransitionUsing:)",
  "metadataVersion" : "0.1.0",
  "role" : "Instance Method",
  "symbol" : {
    "kind" : "Instance Method",
    "modules" : [
      "AVKit"
    ],
    "preciseIdentifier" : "s:5AVKit22AVExperienceControllerC8DelegateP010experienceC0_25prepareForTransitionUsingyAC_AC0H7ContextVtYaF"
  },
  "title" : "experienceController(_:prepareForTransitionUsing:)"
}
-->

# experienceController(_:prepareForTransitionUsing:)

Tells the delegate that the system is preparing for a transition.

```
@MainActor func experienceController(_ controller: AVExperienceController, prepareForTransitionUsing context: AVExperienceController.TransitionContext) async
```

## Parameters

`controller`

The `AVExperienceController`.

`context`

Contains information about the transition.

## Discussion

Implement this method to prepare the app’s state for the [`toExperience`](/documentation/AVKit/AVExperienceController/TransitionContext/toExperience). This may include showing or hiding view controllers, putting the player view controller in the view hierarchy, or any other asynchronous work required for the transition. This is the last chance to update [`configuration`](/documentation/AVKit/AVExperienceController/configuration-swift.property) before the transition begins.

---

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)