<!--
{
  "availability" : [
    "iOS: 9.0.0 -",
    "iPadOS: 9.0.0 -",
    "macCatalyst: 13.1.0 -",
    "macOS: 10.11.0 -",
    "tvOS: 9.0.0 -",
    "visionOS: 1.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "AudioToolbox",
  "identifier" : "/documentation/AudioToolbox/AUAudioUnit/contextName",
  "metadataVersion" : "0.1.0",
  "role" : "Instance Property",
  "symbol" : {
    "kind" : "Instance Property",
    "modules" : [
      "Audio Toolbox"
    ],
    "preciseIdentifier" : "c:objc(cs)AUAudioUnit(py)contextName"
  },
  "title" : "contextName"
}
-->

# contextName

Information about the host context in which the audio unit is connected, for display in the audio unit’s view.

```
var contextName: String? { get set }
```

## Discussion

For example—a host could set “track 3” as the context, so that the audio unit’s view could then display “My audio unit on track 3”.

This version 3 property is bridged to the version 2 `kAudioUnitProperty_ContextName` API.

---

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)