Date formats


Why do Americans use the date format MM/DD/YYYY, while most everyone else uses DD/MM/YYYY?

It makes more sense to have it in ascending order, no?

Please advise,
28 years old
Dublin, Ireland


You’re on the right track, but the fact is that neither of those formats are optimal. There’s only one efficient way to display a date, and that format is: YYYYMMDD.

And notice there are no separators between the years, month and day. When using this format, you don’t need em. Just clump the values together like they’re a big number, and dates can be easily understood and sorted.

For example, take three dates:

  • October 30, 1975 (my birthday)
  • September 24, 2004 (when I moved from NYC to San Francisco)
  • July 4, 1776 (independence day)

Written as YYYYMMDD, they can be easily sorted as regular numbers:

  • 17760704
  • 19751030
  • 20040924

No other regular date format can be compared, sorted, or understood this easily.

In programming, people often get around inefficient the date/time problem by not using dates or times at all. Instead, programmers go by the number of seconds since “Unix epoch,” which is January 1, 1970 (UTC). Not counting leap seconds.

Time should really be counted this way. For example, right now the time is: 1,202,984,940 seconds since epoch.

Rock on,

21 Responses to “Date formats”

  1. 1 clintp February 14, 2008 at 7:20 am

    You didn’t answer the original question.

  2. 2 lance February 14, 2008 at 8:40 am

    BRILLIANT! Best blog yet pud!
    Rock On n Beat Those Drums!

  3. 3 Anonymous February 14, 2008 at 4:54 pm

    Long winded way to avoid saying that Americans are backwards with their inefficient date format, simply to be different from the rest of the world.

  4. 4 Anonymous February 14, 2008 at 5:59 pm

    Actually, pud is right as always. Largest to smallest. Think about if “time” was a factor too…

  5. 5 Anonymous February 14, 2008 at 6:53 pm

    Would you argue with a man who seems to be able to grow straight bananas I know I would’nt.

  6. 6 Anne in SC February 15, 2008 at 2:37 am

    I say we’re all crazy and Pud’s way (the computer way) is what we all should do.

    If you read between the lines, “clintp” you can see that he’s saying we do the way we think best, the others do the way they think best – and I’ll bet no one wants to budge to do it the right way. That’s why in 1st grade (I’m now 39) we started learning things with metric measurements…cause “it’s coming, and we’ll all do it soon”.

    In the meantime, we haven’t budged, and the rest of the world certainly hasn’t budged. And the way technology and everything else changes I bet there’s another way to measure things that none of us are adopting.

  7. 7 Arla February 15, 2008 at 7:29 pm

    Using a bad time format is then of course known as “epoch fail”:

  8. 8 Anonymous February 16, 2008 at 4:06 am

    Ah, schucks pud. Banned!!!!!!!!!!

  9. 9 Jeffrey February 16, 2008 at 3:28 pm

    Great Pud… I’m totally down with the YYYYMMDD format.. makes the most logical sense, easy, etc etc etc. Additionally, if you use this as a naming convention with working files, they will automatically sort out by date for you.. even if the file metadata gets messed up. I also use this format to name my ipod-destined playlists. My ipod is named “Nanite”, and so the playlist of music i want on my ipod is called “nanite list’… i like to save old nanite playlists for postereity, so i name the playlists in itunes “YYYYMMDD Nanite List”.. that way, i can easily look back and see what i was listening to on my ipod last year, last month, etc etc. Nice!

  10. 10 Dan F February 17, 2008 at 10:35 am

    Nope – as well as not answering the question you also didn’t manage to set it in the correct context (think we need Wikipedia to help with that).

    Worst of all, who wants to mention the year first – particularly in the day to day. Only historians, librarians and computer programmers would put the year first.

    The rest of us want to know when it the month.

    Me: “When can you come over?”

    Friend: “How about 20080222?”

    Me: “Huh?!”

    Friend: “Oh, how about 22nd February (or February 22nd?)?”

    Me: “Yeah, cool”.

    A truly logical expression – in your book – would be YYYYMMDDHHMM

    So my friend – if he’s a geek – would say:

    “Great, 200802221930. And let’s grab a refridgerated, fermented, flavoured gluten liquid and cruise for highly evolved bipedal females?”


    “Friday at seven thirty and grab some beer and check out the babes.”

  11. 11 Dr. Shaft February 18, 2008 at 11:58 pm

    As with the metric system, the rest of the world, even the Brits, uses the dd/mm/yyyy format. It really is the most convenient way. We get the usual shaft in the US, all in the name of inertia and wanting to be different–not better–than the rest of the world. That it costs us $1.1 trillion each year to live in the middle ages of measurement seems to go unnoticed. Enjoy the date format, the quarts, the feet, and the ounces!

  12. 12 Anonymous February 19, 2008 at 2:20 pm

    The UNIX epoch time format is playing havoc with archivists. For instance, Menalto’s otherwise excellent software, Gallery, has trouble with photos taken before 1970 because of the way UNIS machines count time FROM 1970. The YYYYMMDD format doesn’t fix this for complicated programming reasons I don’t understand. But it sucks to try to post old photos to UNIX web servers and EXIF/IPTC embed the date and get it to work.

  13. 13 :-Derek February 22, 2008 at 3:16 pm

    Adding to Pud’s wisdom and perspective:

    The method of expressing dates must be convenient and easy to use among humans while also being just as convenient and easy to use for computing purposes. Therefore, a divider between numbers is required. The divider used within data or text is not actually important as long as it is not a number character. Any decent database, which is what Joe Blow programmer is typically using (versus doing actual coding) can pull out the numbers from such a format as long as the numbers are in the correct order and are complete. Gone forever is the ability to be lazy and express a year a ’95’ or ’08’. The full year must be expressed, period, end of argument. Thus 1995 or 2008.

    Resulting example: 2008-02-22, 2008/02/22, 2008_02_22, etc.

    Where the choice of a divider character can be a problem is if you use dates in a file or directory name. You must not use characters reserved by your computer operating system. If you want your files to be cross platform compatible they you have to take into account every possible OS.

    DOS/Windows has a variety of reserved characters: <> : ” / \ | ? *

    Mac OS X reserves the colon (:) and is somwhat picky about the forward slash (/).

    UNIX generally reserves all these characters: ; & ( ) | * ? [ ] ~ { } <> ! ^ ” ‘ \ $ as well as the ASCII characters for newline, space and tab.

    Any OS that uses file extensions is picky about the placement of periods (.) as in ‘2008.02.22’. That name could toss an error, such as asking if you really want to use the ‘.22’ extension.

    Personally, I stick with using the dash (-) as it is safe on all operating system. Another option is the underline character (_) but I find it less elegant.

    Regarding the metric system: We here in the USA are the Luddites of the measurement system world. The fact that we refuse to catch up with the rest of the world is utterly ridiculous as well as expensive.

    And while we’re on the subject of metric, how about dumping our silly time measurement system for something metric? Sadly I don’t think it will every be possible to make our days of the year metric. Instead it would make more sense to make our months strictly follow moon cycles then toss in an adjustment for the mismatch with 364.25 days per revolution around the sun.

  14. 14 Anonymous February 23, 2008 at 12:00 pm

    Dearest Pud,

    1. Surely you must know that the 8 numbers squished together that you call a dat is alot more confusing than any other format.

    2. The trick about New Year’s Resolutions is, you have to start thinking about them in October/November and mentally prepare yourself for the transition that happens in December.

    Isn’t it a cute world,

  15. 15 Anonymous February 24, 2008 at 11:16 am

    YYYYMMDD without seperators will be a problem after year 9999! Think ahead!

  16. 16 David February 28, 2008 at 9:23 pm

    I took to writing dates in yyyy/mm/dd format several years ago, except I don’t think it makes any sense to omit a separator. Here’s an additional rationale for using this format: it eliminates ambiguity. If someone writes “2/3/2008”, there’s no sure way to tell if they meant February 3, 2008 or March 2, 2008.

  17. 17 Anonymous March 9, 2008 at 10:35 am

    There’s no need to store separators.

    You can display the date any way you want, irregardless of it’s stored format.

    The format is simply better for autosort funtions within the database.

  18. 18 Stefan March 13, 2008 at 12:06 pm

    Maybe someone can answer the question why Germans pronounce 123 as “Einhundert-drei-und-zwanzig” (word-by-word translation is one-hundred-three-and-twenty) instead of “Einhundert-zwanzig-[und]-drei” (one-hundred-twenty-[and]-three) like the rest of the world.

  19. 19 Schume March 19, 2008 at 6:41 am

    For computer file names, Pud’s way is best.

    For everyday business use, the American way is best. In 99% of instances where dates are used down to the resolution of a day, the year is already known or assumable, so it’s the least important piece of data.

    “The delivery is due January 20”: The year is obviously next year (if it’s after January) or this year (if it’s before January 20).

    “I first noticed the lump in my breast on March 10.”: This year.

    Of course, there are instances where it’s not so clear: “The new building will open May 15.” But even here, in context, the listeners probably know the year.

    “The Japanese attacked Pearl Harbour on December 7”: Here the year is not so clear (to young people). In context, the year may or may not be important.

    What I’m saying is that if any random 1,000 people were followed around by an invisible investigator for a month, and every instance of a date that they said, wrote, heard, or read were collected and analyzed, the year would rarely be important.

    So the year is not important.

    Of month and day which should come first? The month, as Pub says. The month narrows down the time span to a largish block of time, and the day refines it. Usually the month is more important: We’re more interested that the delivery will happen in X month than that it will happen on the 6th in some mystery month, sometime this year. If you could only know the month or the day, you’d want to know the month.

    So, practically speaking, in everyday personal and business life you want Month Day Year.

  20. 20 USpace April 7, 2008 at 11:49 pm

    I don’t know, Europeans do it differently. I like this way the best: 2/14/08.

    absurd thought –
    God of the Universe
    follows a calendar

  21. 21 DW August 14, 2008 at 4:56 pm

    I’m an American.

    I write my checks and sign documents with the date format: 14 Aug 2008 (the month is written that way to remove confusion)

    For all computer purposes I use: 20080814 or 20080814160735 (whatever makes sense)

    If I speak a date, I say: August 14th or August 14th, 2008 (so I don’t confuse my fellow Um’ericans)

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s

%d bloggers like this: