<!--
{
  "availability" : [
    "watchOS: 2.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "WatchKit",
  "identifier" : "/documentation/WatchKit/WKInterfaceDate",
  "metadataVersion" : "0.1.0",
  "role" : "Class",
  "symbol" : {
    "kind" : "Class",
    "modules" : [
      "WatchKit"
    ],
    "preciseIdentifier" : "c:objc(cs)WKInterfaceDate"
  },
  "title" : "WKInterfaceDate"
}
-->

# WKInterfaceDate

A label that displays the current date or time.

```
class WKInterfaceDate
```

## Overview

Use [`WKInterfaceDate`](/documentation/WatchKit/WKInterfaceDate) when you want to display date or time information without further interaction from your WatchKit extension. At runtime, use the date object to configure the appearance of the date and time information being displayed.

Do not subclass or create instances of this class yourself. Instead, define outlets in your interface controller class and connect them to the corresponding objects in your storyboard file. For example, to refer to a date object in your interface, define a property with the following syntax in your interface controller class:

```objc
@property (weak, nonatomic) IBOutlet WKInterfaceDate* myDate;
```

During the initialization of your interface controller, WatchKit creates any needed date objects and assigns them to their connected outlets. After those objects are set, you can use them to make changes to the onscreen date and time information.

### Interface Builder Configuration Options

Xcode lets you configure information about your date interface object in your storyboard file. The following table lists the attributes you can configure and their meaning.

|Attribute|Description                                                                                                                                                                                                                                                                                                                                                                                                                                                                                 |
|---------|--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
|Format   |A selector for choosing between standard and custom formats. For standard formats, you use the Date and Time attributes to configure the information you want to display. Changing the value of this attribute to Custom lets you configure the date exactly the way you want based on the format options described in [Data Formatting Guide](https://developer.apple.com/library/archive/documentation/Cocoa/Conceptual/DataFormatting/DataFormatting.html#//apple_ref/doc/uid/10000029i).|
|Date     |The date information to display. The date options correspond to the values of the <doc://com.apple.documentation/documentation/Foundation/DateFormatter/Style> type.                                                                                                                                                                                                                                                                                                                        |
|Time     |The time information to display. The time options correspond to the values of the <doc://com.apple.documentation/documentation/Foundation/DateFormatter/Style> type.                                                                                                                                                                                                                                                                                                                        |
|Preview  |A preview of what the date and time will look like.                                                                                                                                                                                                                                                                                                                                                                                                                                         |

A date object is a custom label whose text you cannot set directly. However, you can customize the appearance of the date object as you would customize a label using the Attributes inspector in Xcode. For information about the label attributes you can configure, see [`WKInterfaceLabel`](/documentation/WatchKit/WKInterfaceLabel).

## Topics

### Configuring the Date and Time Display

[`-  setTextColor:`](/documentation/WatchKit/WKInterfaceDate/setTextColor(_:))

Sets the color of the date and time text.

[`-  setTimeZone:`](/documentation/WatchKit/WKInterfaceDate/setTimeZone(_:))

Sets the time zone to use when displaying time information.

[`-  setCalendar:`](/documentation/WatchKit/WKInterfaceDate/setCalendar(_:))

Sets the calendar to use when formatting date information.

## Relationships

### Conforms To

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

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

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

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

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

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

### Inherits From

[`WKInterfaceObject`](/documentation/WatchKit/WKInterfaceObject)

---

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)