<!--
{
  "availability" : [
    "iOS: 2.0.0 -",
    "iPadOS: 2.0.0 -",
    "macCatalyst: 13.0.0 -",
    "macOS: 10.0.0 -",
    "tvOS: 9.0.0 -",
    "visionOS: 1.0.0 -",
    "watchOS: 2.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "Foundation",
  "identifier" : "/documentation/Foundation/NSKeyValueObservingOptions",
  "metadataVersion" : "0.1.0",
  "role" : "Structure",
  "symbol" : {
    "kind" : "Structure",
    "modules" : [
      "Foundation"
    ],
    "preciseIdentifier" : "c:@E@NSKeyValueObservingOptions"
  },
  "title" : "NSKeyValueObservingOptions"
}
-->

# NSKeyValueObservingOptions

The values that can be returned in a change dictionary.

```
struct NSKeyValueObservingOptions
```

## Overview

These constants are passed to <doc://com.apple.documentation/documentation/ObjectiveC/NSObject-swift.class/addObserver(_:forKeyPath:options:context:)> and determine the values that are returned as part of the change dictionary passed to an <doc://com.apple.documentation/documentation/ObjectiveC/NSObject-swift.class/observeValue(forKeyPath:of:change:context:)>. You can pass `0` if you require no change dictionary values.

## Topics

### Constants

[`NSKeyValueObservingOptionNew`](/documentation/Foundation/NSKeyValueObservingOptions/new)

Indicates that the change dictionary should provide the new attribute value, if applicable.

[`NSKeyValueObservingOptionOld`](/documentation/Foundation/NSKeyValueObservingOptions/old)

Indicates that the change dictionary should contain the old attribute value, if applicable.

[`NSKeyValueObservingOptionInitial`](/documentation/Foundation/NSKeyValueObservingOptions/initial)

If specified, a notification should be sent to the observer immediately, before the observer registration method even returns.

[`NSKeyValueObservingOptionPrior`](/documentation/Foundation/NSKeyValueObservingOptions/prior)

Whether separate notifications should be sent to the observer before and after each change, instead of a single notification after the change.

## Relationships

### Conforms To

[`Equatable`](/documentation/Swift/Equatable)

[`Sendable`](/documentation/Swift/Sendable)

[`SetAlgebra`](/documentation/Swift/SetAlgebra)

[`SendableMetatype`](/documentation/Swift/SendableMetatype)

[`ExpressibleByArrayLiteral`](/documentation/Swift/ExpressibleByArrayLiteral)

[`OptionSet`](/documentation/Swift/OptionSet)

[`RawRepresentable`](/documentation/Swift/RawRepresentable)

[`BitwiseCopyable`](/documentation/Swift/BitwiseCopyable)

---

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)