DateList
DateList[] gives the current local date and time in the form {year, month, day, hour, minute, second}. DateList[date] gives a date list for a given date specification.
Examples
Get current date as a list:
DateList[]
(* {2025, 1, 15, 14, 30, 45.123} *)Convert a date string to a list:
DateList["January 1, 2024"]
(* {2024, 1, 1, 0, 0, 0.} *)Get date components from a DateObject:
DateList[Now]
(* {2025, 1, 15, 14, 30, 45.123} *)Please visit the official Wolfram Language Reference for more details.