<!--
{
  "availability" : [
    "iOS: 8.0.0 -",
    "iPadOS: 8.0.0 -",
    "macCatalyst: 13.1.0 -",
    "tvOS: 9.0.0 -",
    "visionOS: 1.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "UIKit",
  "identifier" : "/documentation/UIKit/UICollectionViewDelegate/collectionView(_:didEndDisplayingSupplementaryView:forElementOfKind:at:)",
  "metadataVersion" : "0.1.0",
  "role" : "Instance Method",
  "symbol" : {
    "kind" : "Instance Method",
    "modules" : [
      "UIKit"
    ],
    "preciseIdentifier" : "c:objc(pl)UICollectionViewDelegate(im)collectionView:didEndDisplayingSupplementaryView:forElementOfKind:atIndexPath:"
  },
  "title" : "collectionView(_:didEndDisplayingSupplementaryView:forElementOfKind:at:)"
}
-->

# collectionView(_:didEndDisplayingSupplementaryView:forElementOfKind:at:)

Tells the delegate that the specified supplementary view was removed from the collection view.

```
optional func collectionView(_ collectionView: UICollectionView, didEndDisplayingSupplementaryView view: UICollectionReusableView, forElementOfKind elementKind: String, at indexPath: IndexPath)
```

## Parameters

`collectionView`

The collection view object that removed the supplementary view.

`view`

The view that was removed.

`elementKind`

The type of the supplementary view. This string is defined by the layout that presents the view.

`indexPath`

The index path of the data item that the supplementary view represented.

## Discussion

Use this method to detect when a supplementary view is removed from a collection view, as opposed to monitoring the view itself to see when it appears or disappears.

---

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)