---
title: appearance
framework: xcuiautomation
role: symbol
role_heading: Instance Property
path: xcuiautomation/xcuidevice/appearance-swift.property
---

# appearance

The interface style of the device.

## Declaration

```swift
var appearance: XCUIDevice.Appearance { get set }
```

## Discussion

Discussion Use this property to get or set the interface appearance the system uses for applications running on the device. The example below captures the initial appearance value and sets the device to Dark Mode: let previousAppearance = XCUIDevice.shared.appearance  XCUIDevice.shared.appearance = .dark Set the property once in your test fixture’s setup or intialization code to set an appearance for all the test methods in that fixture.

## See Also

### Interacting with the OS

- [system](xcuiautomation/xcuidevice/system.md)
- [XCUIDevice.Appearance](xcuiautomation/xcuidevice/appearance-swift.enum.md)
