---
title: Iterator
framework: swift
role: symbol
role_heading: Associated Type
path: swift/sequence/iterator
---

# Iterator

A type that provides the sequence’s iteration interface and encapsulates its iteration state.

## Declaration

```swift
associatedtype Iterator : IteratorProtocol
```

## See Also

### Creating an Iterator

- [makeIterator()](swift/sequence/makeiterator().md)
- [Element](swift/sequence/element.md)
