<!--
{
  "availability" : [
    "iOS: 17.0.0 -",
    "iPadOS: 17.0.0 -",
    "macCatalyst: -",
    "tvOS: 17.0.0 -",
    "visionOS: -"
  ],
  "documentType" : "symbol",
  "framework" : "UIKit",
  "identifier" : "/documentation/UIKit/UISceneSessionActivationRequest-swift.struct/userActivity",
  "metadataVersion" : "0.1.0",
  "role" : "Instance Property",
  "symbol" : {
    "kind" : "Instance Property",
    "modules" : [
      "UIKit"
    ],
    "preciseIdentifier" : "s:5UIKit31UISceneSessionActivationRequestV12userActivitySo06NSUserG0CSgvp"
  },
  "title" : "userActivity"
}
-->

# userActivity

A user activity to send to the newly activated scene.

```
var userActivity: NSUserActivity? { get set }
```

## Discussion

The system sends the `userActivity` to the session’s scene upon activation, regardless of whether the scene session already exists.

If you don’t provide a scene session to activate, the system uses the <doc://com.apple.documentation/documentation/Foundation/NSUserActivity/targetContentIdentifier> of the user activity to determine which scene session to activate. When the user activity’s <doc://com.apple.documentation/documentation/Foundation/NSUserActivity/targetContentIdentifier> satisfies the [`prefersToActivateForTargetContentIdentifierPredicate`](/documentation/UIKit/UISceneActivationConditions/prefersToActivateForTargetContentIdentifierPredicate), the system activates that scene’s session to handle the user activity.

---

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)