---
title: endIndex
framework: swift
role: symbol
role_heading: Instance Property
path: swift/unicode/scalar/utf8view/endindex
---

# endIndex

The “past the end” position—that is, the position one greater than the last valid subscript argument.

## Declaration

```swift
var endIndex: Int { get }
```

## Discussion

Discussion If the collection is empty, endIndex is equal to startIndex.
