---
title: XCUIDevice.Button
framework: xcuiautomation
role: symbol
role_heading: Enumeration
path: xcuiautomation/xcuidevice/button
---

# XCUIDevice.Button

A physical button on an iOS device.

## Declaration

```swift
enum Button
```

## Topics

### Device buttons

- [XCUIDevice.Button.home](xcuiautomation/xcuidevice/button/home.md)
- [XCUIDevice.Button.volumeUp](xcuiautomation/xcuidevice/button/volumeup.md)
- [XCUIDevice.Button.volumeDown](xcuiautomation/xcuidevice/button/volumedown.md)
- [XCUIDevice.Button.action](xcuiautomation/xcuidevice/button/action.md)
- [XCUIDevice.Button.camera](xcuiautomation/xcuidevice/button/camera.md)

### Initializers

- [init(rawValue:)](xcuiautomation/xcuidevice/button/init(rawvalue:).md)

## Relationships

### Conforms To

- [BitwiseCopyable](swift/bitwisecopyable.md)
- [Equatable](swift/equatable.md)
- [Hashable](swift/hashable.md)
- [RawRepresentable](swift/rawrepresentable.md)
- [Sendable](swift/sendable.md)
- [SendableMetatype](swift/sendablemetatype.md)

## See Also

### Interacting with buttons and the Digital Crown

- [press(_:)](xcuiautomation/xcuidevice/press(_:).md)
- [hasHardwareButton(_:)](xcuiautomation/xcuidevice/hashardwarebutton(_:).md)
- [rotateDigitalCrown(delta:)](xcuiautomation/xcuidevice/rotatedigitalcrown(delta:).md)
- [rotateDigitalCrown(delta:velocity:)](xcuiautomation/xcuidevice/rotatedigitalcrown(delta:velocity:).md)
