<!--
{
  "availability" : [
    "iOS: 27.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "AudioAccessoryKit",
  "identifier" : "/documentation/AudioAccessoryKit/AudioAccessoryHeadTracking/Handler/headTrackingStateDidChange(isActive:)",
  "metadataVersion" : "0.1.0",
  "role" : "Instance Method",
  "symbol" : {
    "kind" : "Instance Method",
    "modules" : [
      "AudioAccessoryKit"
    ],
    "preciseIdentifier" : "s:17AudioAccessoryKit0aB12HeadTrackingC7HandlerP04headE14StateDidChange8isActiveySb_tF"
  },
  "title" : "headTrackingStateDidChange(isActive:)"
}
-->

# headTrackingStateDidChange(isActive:)

Called when the user-facing Head Tracking state for this accessory
changes (e.g. via Settings or Control Center).

```
func headTrackingStateDidChange(isActive: Bool)
```

## Parameters

`isActive`

`true` when head tracking is enabled and the
extension should stream IMU samples via
`Session.sendDataToAudioExtension(_:)`; `false` when head tracking
is disabled and the extension should stop sampling.

## Discussion

Implementations should start or stop sampling the accessory’s IMU
based on the new 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)