Loading lesson path
The Temporal.PlainDateTime Object
Temporal.PlainDateTime object is a pure date and time object.
Formula
It represents a calendar date and a wall - clock time with no time zone.Formula
2026 - 05 - 07T14:30:00.Formula
// Create a PlainDateTime object const dateTime = Temporal.PlainDateTime.from("2026 - 05 - 17T14:30:00");is a literal to separate the date from the time.
How to use JavaScript Temporal.PlainDateTime How to work with date and time without a time zone
PlainDateTime is useful when you need both date and time, but not time zone.
An PlainDateTime object can be created in several different ways:
Constructor (new) new Temporal.PlainDateTime()
Temporal.PlainDateTime.from() Now (current time) Temporal.Now.plainDateTimeISO()
PlainDateTime object using the new constructor. The constructor takes parameters like year, month, day, hours, and minutes.
// Create a PlainDateTime object const date = new Temporal.PlainDateTime(2026, 5, 17, 14, 30);In Temporal objects, months start at 1. In the legasy Date object, months start at 0.
Formula
ISO 8601 / RFC 9557 string.Formula
// Create a PlainDateTime object const dateTime = Temporal.PlainDateTime.from("2026 - 05 - 17T10:00:00");is a literal to separate the date from the time. You should read it as an abbreviation for Time.
ISO 8601 format.
PlainDateTime object from current time.