parseDate

Learn how to use the parseDate function in Notion formulas.

New in Formulas 2.0

The parseDate() function takes an ISO 8601-formatted date string (an international standard) and returns it as a date object.

parseDate(string) string.parseDate()

A standard ISO 8601-formatted date looks like the following. The dashes - and colons : are optional but are recommended for readability.

YYYY-MM-DDTHH:MM:SSZ YYYYMMDDTHHMMSSZ

Each date and time value requires a fixed number of digits that are padded with leading zeros.

TokenItemValuesNotes
YYYYYear00009999
MMMonth0112
DDDate0131
TTimeRequired between the date and the time
HHHour0023
MMMinute0059
SSSecondNotion does not support seconds in date objects
ZTimezone OffsetZ
+00:00
-01:00
Z can be used as is (zero offset UTC), or alternatively options like +01:00 and -04:00 can be used directly following the time
parseDate("2023-07-29") /* Output: July 29, 2023 */ "20151021T1608".parseDate() /* Output: October 21, 2015 4:08 PM */

While you’ll likely only need to use the standard YYYY-MM-DDTHH:MM:SSZ tokens, there are also some others that are supported.

Week dates utilise a year number, an ISO week date number, and a day of the week number.

YYYY-Www-D YYYYWwwD
TokenItemValuesNotes
YYYYYear0000 – 9999
WwwWeekW01 – W53
DDay1 – 71 = Monday, 7 = Sunday, etc.
"2020-W01-1".parseDate() /* Output: December 30, 2019 */ parseDate("2020-W53-7") /* Output: January 3, 2021 */

Ordinal dates utilise a year number and a day of the year number.

YYYY-DDD YYYYDDD
TokenItemValuesNotes
YYYYYear0000 – 9999
DDDDay of the year001 – 366Predictably, 366 only works for leap years
parseDate("1981-095") /* Output: December 29, 2008 */ "2015-294T04:08".parseDate() /* Output: October 21, 2015 4:08 PM */
About the Author

My name is Thomas Frank, and I'm a Notion-certified writer, YouTuber, and template creator. I've been using Notion since 2018 to organize my personal life and to run my business and YouTube channel. In addition to this formula reference, I've created a free Notion course for beginners and several productivity-focused Notion templates. If you'd like to connect, follow me on Twitter.

🤔 Have an UB Question?

Fill out the form below and I’ll answer as soon as I can! ~Thomas

🤔 Have a Question?

Fill out the form below and I’ll answer as soon as I can! ~Thomas