<!--
{
  "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/init(arrangedSubviews:)",
  "metadataVersion" : "0.1.0",
  "role" : "Initializer",
  "symbol" : {
    "kind" : "Initializer",
    "modules" : [
      "UIKit"
    ],
    "preciseIdentifier" : "c:objc(cs)UIStackView(im)initWithArrangedSubviews:"
  },
  "title" : "init(arrangedSubviews:)"
}
-->

# init(arrangedSubviews:)

Returns a new stack view object that manages the provided views.

```
convenience init(arrangedSubviews views: [UIView])
```

## Parameters

`views`

The views to be arranged by the stack view.

## Return Value

A new stack view object. This stack view contains and lays out the provided views in a single stack. You can modify the orientation or appearance of this stack, using the stack view’s properties.

## Discussion

The stack view adds all the arranged views to its [`arrangedSubviews`](/documentation/UIKit/UIStackView/arrangedSubviews) array. It also adds these views as subviews. If any view contained in the `arrangedSubviews` array receives a [`removeFromSuperview()`](/documentation/UIKit/UIView/removeFromSuperview()) method call, the stack view also removes it from the `arrangedSubviews`.

## See Also

[`-  insertArrangedSubview:atIndex:`](/documentation/UIKit/UIStackView/insertArrangedSubview(_:at:))

Adds the provided view to the array of arranged subviews at the specified index.

[`-  removeFromSuperview`](/documentation/UIKit/UIView/removeFromSuperview())

Unlinks the view from its superview and its window, and removes it from the responder chain.

[`arrangedSubviews`](/documentation/UIKit/UIStackView/arrangedSubviews)

The list of views arranged by the stack view.

[`-  addArrangedSubview:`](/documentation/UIKit/UIStackView/addArrangedSubview(_:))

Adds a view to the end of the arranged subviews array.

[`-  removeArrangedSubview:`](/documentation/UIKit/UIStackView/removeArrangedSubview(_:))

Removes the provided view from the stack’s array of arranged subviews.



---

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)