---
title: UIInterfaceOrientation
framework: uikit
role: symbol
role_heading: Enumeration
path: uikit/uiinterfaceorientation
---

# UIInterfaceOrientation

Constants that specify the orientation of the app’s user interface.

## Declaration

```swift
enum UIInterfaceOrientation
```

## Overview

Overview Starting in iOS 8, you should employ the UITraitCollection and UITraitEnvironment APIs, and size class properties as used in those APIs, instead of using UIInterfaceOrientation constants or otherwise writing your app in terms of interface orientation. In earlier versions of iOS, you used these constants in the statusBarOrientation property and the setStatusBarOrientation(_:animated:) method. important: Notice that UIDeviceOrientation.landscapeRight is assigned to UIInterfaceOrientation.landscapeLeft and UIDeviceOrientation.landscapeLeft is assigned to UIInterfaceOrientation.landscapeRight. The reason for this is that rotating the device requires rotating the content in the opposite direction.

## Topics

### Orientations

- [UIInterfaceOrientation.unknown](uikit/uiinterfaceorientation/unknown.md)
- [UIInterfaceOrientation.portrait](uikit/uiinterfaceorientation/portrait.md)
- [UIInterfaceOrientation.portraitUpsideDown](uikit/uiinterfaceorientation/portraitupsidedown.md)
- [UIInterfaceOrientation.landscapeLeft](uikit/uiinterfaceorientation/landscapeleft.md)
- [UIInterfaceOrientation.landscapeRight](uikit/uiinterfaceorientation/landscaperight.md)

### Orientation Checks

- [isLandscape](uikit/uiinterfaceorientation/islandscape.md)
- [isPortrait](uikit/uiinterfaceorientation/isportrait.md)

### Initializers

- [init(rawValue:)](uikit/uiinterfaceorientation/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

### Managing interface geometry

- [application(_:supportedInterfaceOrientationsFor:)](uikit/uiapplicationdelegate/application(_:supportedinterfaceorientationsfor:).md)
- [UIInterfaceOrientationMask](uikit/uiinterfaceorientationmask.md)
- [invalidInterfaceOrientationException](uikit/uiapplication/invalidinterfaceorientationexception.md)
