<!--
{
  "availability" : [
    "iOS: 27.0.0 -",
    "iPadOS: 27.0.0 -",
    "macCatalyst: 27.0.0 -",
    "macOS: 27.0.0 -",
    "tvOS: 27.0.0 -",
    "visionOS: 27.0.0 -",
    "watchOS: 27.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "Swift",
  "identifier" : "/documentation/Swift/Iterable",
  "metadataVersion" : "0.1.0",
  "role" : "Protocol",
  "symbol" : {
    "kind" : "Protocol",
    "modules" : [
      "Swift"
    ],
    "preciseIdentifier" : "s:s8IterableP"
  },
  "title" : "Iterable"
}
-->

# Iterable

A type that provides sequential, borrowing access to its elements.

```
protocol Iterable<Element, Failure> : ~Copyable, ~Escapable
```

## Topics

### Associated Types

[`associatedtype BorrowingIterator : BorrowingIteratorProtocol, ~Copyable, ~Escapable`](/documentation/Swift/Iterable/BorrowingIterator)

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

[`associatedtype Element : ~Copyable`](/documentation/Swift/Iterable/Element)

A type representing the sequence’s elements.

[`associatedtype Failure = Never`](/documentation/Swift/Iterable/Failure)

### Instance Properties

[`var underestimatedCount: Int`](/documentation/Swift/Iterable/underestimatedCount)

A value less than or equal to the number of elements in the sequence,
calculated nondestructively.

### Instance Methods

[`func makeBorrowingIterator() -> Self.BorrowingIterator`](/documentation/Swift/Iterable/makeBorrowingIterator())

Returns a borrowing iterator over the elements of this sequence.

## Relationships

### Conforming Types

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

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

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

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

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

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

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

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

---

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)