<!--
{
  "availability" : [
    "iOS: 17.0.0 -",
    "iPadOS: 17.0.0 -",
    "macCatalyst: 17.0.0 -",
    "tvOS: 17.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "UIKit",
  "identifier" : "/documentation/UIKit/UITextLoupeSession",
  "metadataVersion" : "0.1.0",
  "role" : "Class",
  "symbol" : {
    "kind" : "Class",
    "modules" : [
      "UIKit"
    ],
    "preciseIdentifier" : "c:objc(cs)UITextLoupeSession"
  },
  "title" : "UITextLoupeSession"
}
-->

# UITextLoupeSession

An object that manages the presentation of the system magnifier at the location you specify.

```
@MainActor class UITextLoupeSession
```

## Overview

A [`UITextLoupeSession`](/documentation/UIKit/UITextLoupeSession) object programmatically displays the system loupe in your view. You might display this view to allow someone to magnify your view’s content. Typically, you display the loupe from a [`UIPanGestureRecognizer`](/documentation/UIKit/UIPanGestureRecognizer) when someone interacts with your view. As the location in the gesture recognizer changes, use the loupe session object to update the position of the loupe.

## Topics

### Creating the loupe session

[`class func begin(at: CGPoint, fromSelectionWidgetView: UIView?, in: UIView) -> Self?`](/documentation/UIKit/UITextLoupeSession/begin(at:fromSelectionWidgetView:in:))

Creates a new loupe session and displays the loupe at the specified location in your view.

### Updating the loupe during the session

[`func move(to: CGPoint, withCaretRect: CGRect, trackingCaret: Bool)`](/documentation/UIKit/UITextLoupeSession/move(to:withCaretRect:trackingCaret:))

Moves the loupe to the specified point in the session’s associated view.

[`func invalidate()`](/documentation/UIKit/UITextLoupeSession/invalidate())

Hides the loupe and cleans up any session-related state.

## Relationships

### Conforms To

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

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

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

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

[`NSObjectProtocol`](/documentation/ObjectiveC/NSObjectProtocol)

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

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

### Inherits From

[`NSObject-swift.class`](/documentation/ObjectiveC/NSObject-swift.class)

---

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)