<!--
{
  "availability" : [
    "iOS: 26.0 -",
    "iPadOS: 26.0 -",
    "macCatalyst: 26.0 -",
    "macOS: 26.0 -",
    "visionOS: 26.0 -",
    "watchOS: 26.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "RelevanceKit",
  "identifier" : "/documentation/RelevanceKit",
  "metadataVersion" : "0.1.0",
  "role" : "Framework",
  "symbol" : {
    "kind" : "Framework",
    "modules" : [
      "RelevanceKit"
    ],
    "preciseIdentifier" : "RelevanceKit"
  },
  "title" : "RelevanceKit"
}
-->

# RelevanceKit

Provide on-device intelligence with contextual clues that increase your widget’s visibility on Apple Watch.

## Overview

On Apple Watch, widgets appear in the Smart Stack in an order that best fits a person’s context.
To order the widgets that appear in the Smart Stack, watchOS attempts to determine a widget’s relevance based on several factors,
including contextual clues your app provides to the system.

To give your widget additional visibility in the watchOS Smart Stack and ensure it appears when a person needs it,
use RelevanceKit to provide contextual clues that signal the widget’s relevance to the system. For example, your widget might be most useful
at a specific location or time, or every time a person starts a workout.

Note that you use RelevanceKit in combination with <doc://com.apple.documentation/documentation/WidgetKit> and
<doc://com.apple.documentation/documentation/AppIntents> to provide interactive and contextually relevant widgets in the Smart Stack,
including iPhone widgets that appear on Apple Watch. When you add an
import statement for App Intents to your code, App Intents implicitly adds a dependence to RelevanceKit .
You don’t need to explicitly add `import RelevanceKit` to your code.

For more information, refer to <doc://com.apple.documentation/documentation/WidgetKit/Widget-Suggestions-In-Smart-Stacks>.

> Note: Smart Stacks are available in iOS, iPadOS, and watchOS. However, functionality provided by RelevanceKit is only available in
> watchOS. Calling its API on other platforms doesn’t have any effect.

## Topics

### Providing relevance information

  <doc://com.apple.documentation/documentation/WidgetKit/Widget-Suggestions-In-Smart-Stacks>

[`struct RelevantContext`](/documentation/RelevanceKit/RelevantContext)

Contextual clues the system uses to show relevant widgets in the Smart Stack on watchOS.

### Fitness clues

[`static func fitness(RelevantContext.FitnessCondition) -> RelevantContext`](/documentation/RelevanceKit/RelevantContext/fitness(_:))

Tells the system a widget is relevant because of a person’s fitness activity.

[`struct FitnessCondition`](/documentation/RelevanceKit/RelevantContext/FitnessCondition)

Values that represent a person’s fitness activity.

### Hardware clues

[`static func hardware(headphones: RelevantContext.HeadphonesCondition) -> RelevantContext`](/documentation/RelevanceKit/RelevantContext/hardware(headphones:))

Tells the system a widget is relevant when a person’s headphones are connected.

[`struct HeadphonesCondition`](/documentation/RelevanceKit/RelevantContext/HeadphonesCondition)

A structure that indicates whether a person’s headphones are connected.

### Location clues

[`static func location(CLRegion) -> RelevantContext`](/documentation/RelevanceKit/RelevantContext/location(_:))

Tells the system a widget is relevant at a specific location.

[`static func location(inferred: RelevantContext.InferredLocation) -> RelevantContext`](/documentation/RelevanceKit/RelevantContext/location(inferred:))

Tells the system a widget is relevant at a person’s inferred location.

[`struct InferredLocation`](/documentation/RelevanceKit/RelevantContext/InferredLocation)

A structure with values for a person’s inferred home, work, school, and commute locations.

### Sleep clues

[`static func sleep(RelevantContext.SleepCondition) -> RelevantContext`](/documentation/RelevanceKit/RelevantContext/sleep(_:))

Tells the system a widget is relevant because of a person’s sleep schedule.

[`struct SleepCondition`](/documentation/RelevanceKit/RelevantContext/SleepCondition)

Values that represent a person’s typical bedtime or wakeup time.

### Time clues

[`static func date(Date) -> RelevantContext`](/documentation/RelevanceKit/RelevantContext/date(_:))

Tells the system a widget is relevant at a specific date.

[`static func date(Date, kind: RelevantContext.DateKind) -> RelevantContext`](/documentation/RelevanceKit/RelevantContext/date(_:kind:))

Tells the system a widget is relevant at a specific date and provides an additional contextual hint.

[`static func date(interval: DateInterval, kind: RelevantContext.DateKind) -> RelevantContext`](/documentation/RelevanceKit/RelevantContext/date(interval:kind:))

Tells the system a widget is relevant for a time interval and provides an additional contextual hint.

[`static func date(range: ClosedRange<Date>, kind: RelevantContext.DateKind) -> RelevantContext`](/documentation/RelevanceKit/RelevantContext/date(range:kind:))

Tells the system a widget is relevant for a known date range and provides an additional contextual hint.

[`struct DateKind`](/documentation/RelevanceKit/RelevantContext/DateKind)

Values the system uses as additional context for time-based relevance clues.

[`static func date(from: Date, to: Date) -> RelevantContext`](/documentation/RelevanceKit/RelevantContext/date(from:to:))

Tells the system a widget is relevant between two dates.



---

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)