---
title: "applySnapshot(_:toSection:animatingDifferences:)"
framework: uikit
role: symbol
role_heading: Instance Method
path: "uikit/uicollectionviewdiffabledatasourcereference/applysnapshot(_:tosection:animatingdifferences:)"
---

# applySnapshot(_:toSection:animatingDifferences:)

Updates the section UI to reflect the state of the data in the specified snapshot, optionally animating the UI changes.

## Declaration

```swift
func applySnapshot(_ snapshot: NSDiffableDataSourceSectionSnapshotReference, toSection sectionIdentifier: Any, animatingDifferences: Bool)
```

## See Also

### Updating section data

- [snapshot(forSection:)](uikit/uicollectionviewdiffabledatasourcereference/snapshot(forsection:).md)
- [applySnapshot(_:toSection:animatingDifferences:completion:)](uikit/uicollectionviewdiffabledatasourcereference/applysnapshot(_:tosection:animatingdifferences:completion:).md)
