<!--
{
  "availability" : [
    "iOS: 15.0.0 -",
    "iPadOS: 15.0.0 -",
    "macCatalyst: 15.0.0 -",
    "macOS: 12.0.0 -",
    "tvOS: 15.0.0 -",
    "visionOS: 1.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "GroupActivities",
  "identifier" : "/documentation/GroupActivities/GroupSession/end()",
  "metadataVersion" : "0.1.0",
  "role" : "Instance Method",
  "symbol" : {
    "kind" : "Instance Method",
    "modules" : [
      "Group Activities"
    ],
    "preciseIdentifier" : "s:15GroupActivities0A7SessionC3endyyF"
  },
  "title" : "end()"
}
-->

# end()

Ends the activity for the entire group and stops the transfer
of synchronized data.

```
final func end()
```

## Discussion

Call this method to end the activity for all participants.
When you call this method, the session transitions to the [`GroupSession.State.invalidated(reason:)`](/documentation/GroupActivities/GroupSession/State-swift.enum/invalidated(reason:))
state and stops the delivery of session-related updates. After ending
the session, you can’t join it again.

Don’t call this method on a session already in the [`GroupSession.State.invalidated(reason:)`](/documentation/GroupActivities/GroupSession/State-swift.enum/invalidated(reason:)) state.

---

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)