<!--
{
  "availability" : [
    "iOS: 9.0.0 -",
    "iPadOS: 9.0.0 -",
    "macCatalyst: 13.1.0 -",
    "tvOS: 9.0.0 -",
    "visionOS: 1.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "UIKit",
  "identifier" : "/documentation/UIKit/UIStackView/Alignment-swift.enum/center",
  "metadataVersion" : "0.1.0",
  "role" : "Case",
  "symbol" : {
    "kind" : "Case",
    "modules" : [
      "UIKit"
    ],
    "preciseIdentifier" : "c:@E@UIStackViewAlignment@UIStackViewAlignmentCenter"
  },
  "title" : "UIStackView.Alignment.center"
}
-->

# UIStackView.Alignment.center

A layout where the stack view aligns the center of its arranged views with its center along its axis.

```
case center
```

## Discussion

The following image shows an example of a horizontal stack view that uses the [`UIStackView.Alignment.center`](/documentation/UIKit/UIStackView/Alignment-swift.enum/center) alignment.

![A horizontal stack view with four arranged subviews. The stack view aligns the subviews by their centers along the stack view’s axis.](images/com.apple.uikit/media-2557468@2x.png)

---

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)