What is the significance of December 31, 1969?

I was fooling around with the Time class in Ruby and figured out I could convert the current time to an integer.

Integer(Time.now)
=> 1408000367

I casually noticed it wasn’t a random number being generated, that it seemed to be some sort of counter…in seconds. That led me to the inevitable…

Time.at(0)
=> 1969-12-31 16:00:00 -0800

December 31, 1969 at 4pm (PST) or January 1, 1970 (UTC). It led me on a sort of wild goose chase. WHY exactly is midnight January 1, 1970 being used as the zero hour? From the Ruby doc:

Time is stored internally as the number of seconds with fraction since the Epoch, January 1, 1970 00:00 UTC. 

What’s an “Epoch”?

the beginning of a distinctive period in the history of someone or something.

Okay, so we’re back at my original question, “WHY exactly is midnight January 1, 1970 being used as the ‘epoch’?”

Wikipedia, can you help?

The Unix epoch is the time 00:00:00 UTC on 1 January 1970 (or 1970-01-01T00:00:00Z ISO 8601). There is a problem with this definition, in that UTC did not exist in its current form until 1972

Oh boy…How about Stack Overflow?

 The programmers chose the arbitrary date of January 1, 1971 GMT to be epoch time. This was partly due to the fact that older computers couldn’t handle large numbers so the date had to be in the recent past. Afterwards, epoch time was adjusted to be Jan 1, 1970 so as to be a nice, round number.

So basically, nothing “happened” on that date. It was an arbitrary date chosen based on the original time of the work being done.

Ahh, that sounds about right.

Leave a Reply