<!--
{
  "availability" : [
    "iOS: -",
    "iPadOS: -",
    "macCatalyst: -",
    "macOS: -",
    "tvOS: -",
    "visionOS: -",
    "watchOS: -"
  ],
  "documentType" : "symbol",
  "framework" : "ObjectiveC",
  "identifier" : "/documentation/ObjectiveC/NSObject-swift.class/mutableArrayValue(forKeyPath:)",
  "metadataVersion" : "0.1.0",
  "role" : "Instance Method",
  "symbol" : {
    "kind" : "Instance Method",
    "modules" : [
      "Objective-C Runtime",
      "ObjectiveC"
    ],
    "preciseIdentifier" : "c:objc(cs)NSObject(im)mutableArrayValueForKeyPath:"
  },
  "title" : "mutableArrayValue(forKeyPath:)"
}
-->

# mutableArrayValue(forKeyPath:)

Returns a mutable array that provides read-write access to the ordered to-many relationship specified by a given key path.

```
func mutableArrayValue(forKeyPath keyPath: String) -> NSMutableArray
```

## Parameters

`keyPath`

A key path, relative to the receiver, to an ordered to-many relationship.

## Return Value

A mutable array that provides read-write access to the ordered to-many relationship specified by `keyPath`.

## Discussion

See [`mutableArrayValue(forKey:)`](/documentation/ObjectiveC/NSObject-swift.class/mutableArrayValue(forKey:)) for additional details.

---

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)