<!--
{
  "availability" : [
    "iOS: 26.0.0 -",
    "iPadOS: 26.0.0 -",
    "macCatalyst: 26.0.0 -",
    "macOS: 26.0.0 -",
    "tvOS: 26.0.0 -",
    "visionOS: 26.0.0 -",
    "watchOS: 26.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "Foundation",
  "identifier" : "/documentation/Foundation/NotificationCenter/ObservationToken",
  "metadataVersion" : "0.1.0",
  "role" : "Structure",
  "symbol" : {
    "kind" : "Structure",
    "modules" : [
      "Foundation"
    ],
    "preciseIdentifier" : "s:So20NSNotificationCenterC10FoundationE16ObservationTokenV"
  },
  "title" : "NotificationCenter.ObservationToken"
}
-->

# NotificationCenter.ObservationToken

A unique token representing a single observer registration in a notification center.

```
struct ObservationToken
```

## Overview

You receive the `ObservationToken` type as a return value from `addObserver(of:for:using:)` and related methods.

Retain the `ObservationToken` for as long as you need to continue observation, since observation ends when the token goes out of scope.
You can also explicitly stop observing by passing the token to `removeObserver(_:)-(ObservationToken)`.

---

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)