<!--
{
  "availability" : [
    "iOS: 10.0.0 -",
    "iPadOS: 10.0.0 -",
    "macCatalyst: 13.1.0 -",
    "macOS: 10.14.0 -",
    "tvOS: 10.0.0 -",
    "visionOS: 1.0.0 -",
    "watchOS: 3.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "UserNotifications",
  "identifier" : "/documentation/UserNotifications/UNCalendarNotificationTrigger",
  "metadataVersion" : "0.1.0",
  "role" : "Class",
  "symbol" : {
    "kind" : "Class",
    "modules" : [
      "User Notifications"
    ],
    "preciseIdentifier" : "c:objc(cs)UNCalendarNotificationTrigger"
  },
  "title" : "UNCalendarNotificationTrigger"
}
-->

# UNCalendarNotificationTrigger

A trigger condition that causes a notification the system delivers at a specific date and time.

```
class UNCalendarNotificationTrigger
```

## Overview

Create a [`UNCalendarNotificationTrigger`](/documentation/UserNotifications/UNCalendarNotificationTrigger) object when you want to schedule the delivery of a local notification at the date and time you specify. You use an <doc://com.apple.documentation/documentation/Foundation/NSDateComponents> object to specify only the time values that you want the system to use to determine the matching date and time.

Listing 1 creates a trigger that delivers its notification every morning at 8:30. The repeating behavior is achieved by specifying `true` for the `repeats` parameter when creating the trigger.

Listing 1. Creating a trigger that repeats at a specific time

```swift
var date = DateComponents()
date.hour = 8
date.minute = 30 
let trigger = UNCalendarNotificationTrigger(dateMatching: date, repeats: true)
```

## Topics

### Creating a Calendar Trigger

[`init(dateMatching:repeats:)`](/documentation/UserNotifications/UNCalendarNotificationTrigger/init(dateMatching:repeats:))

Creates a calendar trigger using the date components parameter.

### Getting the Trigger Information

[`nextTriggerDate()`](/documentation/UserNotifications/UNCalendarNotificationTrigger/nextTriggerDate())

The next date at which the trigger conditions are met.

[`dateComponents`](/documentation/UserNotifications/UNCalendarNotificationTrigger/dateComponents)

The date components to construct this object.



---

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)