<!--
{
  "availability" : [
    "iOS: 27.2.0 -",
    "iPadOS: 27.2.0 -",
    "macCatalyst: 27.2.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "HomeExtensions",
  "identifier" : "/documentation/HomeExtensions/HomeAccessoryToggleSetting",
  "metadataVersion" : "0.1.0",
  "role" : "Class",
  "symbol" : {
    "kind" : "Class",
    "modules" : [
      "HomeExtensions"
    ],
    "preciseIdentifier" : "s:14HomeExtensions0A22AccessoryToggleSettingC"
  },
  "title" : "HomeAccessoryToggleSetting"
}
-->

# HomeAccessoryToggleSetting

A setting that offers a binary choice, such as on or off.

```
@propertyWrapper final class HomeAccessoryToggleSetting
```

## Overview

The Home app displays this setting as a toggle.

## Topics

### Creating a toggle setting

[`init(id: String, label: HomeAccessorySettingLabel, isEnabled: Bool, defaultValue: Bool?, currentValue: Bool?, onLabel: HomeAccessorySettingLabel?, offLabel: HomeAccessorySettingLabel?)`](/documentation/HomeExtensions/HomeAccessoryToggleSetting/init(id:label:isEnabled:defaultValue:currentValue:onLabel:offLabel:))

Creates a toggle setting.

### Configuring presentation

[`var label: HomeAccessorySettingLabel`](/documentation/HomeExtensions/HomeAccessoryToggleSetting/label)

The label to display for this setting.

[`var isEnabled: Bool`](/documentation/HomeExtensions/HomeAccessoryToggleSetting/isEnabled)

A Boolean value that indicates whether people can change the setting.

[`var isHidden: Bool`](/documentation/HomeExtensions/HomeAccessoryToggleSetting/isHidden)

A Boolean value that indicates whether the setting is hidden.

### Accessing the value

[`var wrappedValue: Bool?`](/documentation/HomeExtensions/HomeAccessoryToggleSetting/wrappedValue)

The setting’s current value, or its default value if it has none.

[`var projectedValue: HomeAccessoryToggleSetting`](/documentation/HomeExtensions/HomeAccessoryToggleSetting/projectedValue)

The setting itself, which you access with a dollar sign prefix.

### Instance Properties

[`let id: String`](/documentation/HomeExtensions/HomeAccessoryToggleSetting/id)

A unique identifier for the setting.

## Relationships

### Conforms To

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

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

[`HomeAccessorySetting`](/documentation/HomeExtensions/HomeAccessorySetting)

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

---

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)