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

# UIFocusUpdateContext

An object that provides information relevant to a specific focus update from one view to another.

```
@MainActor class UIFocusUpdateContext
```

## Overview

Focus update context objects are ephemeral and are usually discarded after the update is finished. The `UIFocus` APIs create a single high-level software interface for controlling focus in apps that use focus-based input.

## Topics

### Locating focus direction

[`previouslyFocusedView`](/documentation/UIKit/UIFocusUpdateContext/previouslyFocusedView)

The view that was focused before the focus update.

[`nextFocusedView`](/documentation/UIKit/UIFocusUpdateContext/nextFocusedView)

The view that takes the focus after the focus update.

[`focusHeading`](/documentation/UIKit/UIFocusUpdateContext/focusHeading)

The heading in which the focus update is occurring.

[`UIFocusHeading`](/documentation/UIKit/UIFocusHeading)

The general type of an event.

### Getting related focus items

[`previouslyFocusedItem`](/documentation/UIKit/UIFocusUpdateContext/previouslyFocusedItem)

The item that was focused before the update.

[`nextFocusedItem`](/documentation/UIKit/UIFocusUpdateContext/nextFocusedItem)

The item to be focused after the update.

### Responding to focus-related keys and notifications

[`UIFocusDidUpdateNotification`](/documentation/UIKit/UIFocusSystem/didUpdateNotification)

The focus for the UI has been updated.

[`UIFocusMovementDidFailNotification`](/documentation/UIKit/UIFocusSystem/movementDidFailNotification)

The focus failed to move to another item.

[`UIFocusUpdateAnimationCoordinatorKey`](/documentation/UIKit/UIFocusSystem/animationCoordinatorUserInfoKey)

Updates the animation coordinator.

[`UIFocusUpdateContextKey`](/documentation/UIKit/UIFocusSystem/focusUpdateContextUserInfoKey)

Updates the context key.

## Relationships

### Inherits From

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

### Conforms To

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

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

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

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

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

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

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

### Inherited By

[`UITableViewFocusUpdateContext`](/documentation/UIKit/UITableViewFocusUpdateContext)

[`UICollectionViewFocusUpdateContext`](/documentation/UIKit/UICollectionViewFocusUpdateContext)

---

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)