<!--
{
  "availability" : [
    "iOS: 13.0.0 -",
    "iPadOS: 13.0.0 -",
    "macCatalyst: 13.1.0 -",
    "tvOS: 13.0.0 -",
    "visionOS: 1.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "UIKit",
  "identifier" : "/documentation/UIKit/NSCollectionLayoutGroupCustomItem",
  "metadataVersion" : "0.1.0",
  "role" : "Class",
  "symbol" : {
    "kind" : "Class",
    "modules" : [
      "UIKit"
    ],
    "preciseIdentifier" : "c:objc(cs)NSCollectionLayoutGroupCustomItem"
  },
  "title" : "NSCollectionLayoutGroupCustomItem"
}
-->

# NSCollectionLayoutGroupCustomItem

An item used in a group with a custom layout arrangement.

```
@MainActor class NSCollectionLayoutGroupCustomItem
```

## Overview

You use a custom item if you want to specify a layout with a custom arrangement, like a radial or diagonal layout. You use custom items within a group that’s created with [`custom(layoutSize:itemProvider:)`](/documentation/UIKit/NSCollectionLayoutGroup/custom(layoutSize:itemProvider:)).

Instead of providing a layout size for the custom item, like you do when you create an [`NSCollectionLayoutItem`](/documentation/UIKit/NSCollectionLayoutItem), you provide a frame instead.

## Topics

### Creating a custom item

[`+  customItemWithFrame:`](/documentation/UIKit/NSCollectionLayoutGroupCustomItem/init(frame:))

Creates a custom item with the specified frame.

[`+  customItemWithFrame:zIndex:`](/documentation/UIKit/NSCollectionLayoutGroupCustomItem/init(frame:zIndex:))

Creates a custom item with the specified frame and vertical stacking order in relation to other items in the group.

### Getting the frame

[`frame`](/documentation/UIKit/NSCollectionLayoutGroupCustomItem/frame)

The frame of the custom item.

### Specifying stacking order

[`zIndex`](/documentation/UIKit/NSCollectionLayoutGroupCustomItem/zIndex)

The vertical stacking order of the custom item in relation to other items in the group.

## Relationships

### Conforms To

[`CustomStringConvertible`](/documentation/Swift/CustomStringConvertible)

[`CVarArg`](/documentation/Swift/CVarArg)

[`NSCopying`](/documentation/Foundation/NSCopying)

[`Equatable`](/documentation/Swift/Equatable)

[`Hashable`](/documentation/Swift/Hashable)

[`NSObjectProtocol`](/documentation/ObjectiveC/NSObjectProtocol)

[`CustomDebugStringConvertible`](/documentation/Swift/CustomDebugStringConvertible)

[`Sendable`](/documentation/Swift/Sendable)

### Inherits From

[`NSObject-swift.class`](/documentation/ObjectiveC/NSObject-swift.class)

---

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)