Take the 2-minute tour ×
Mathematica Stack Exchange is a question and answer site for users of Mathematica. It's 100% free, no registration required.

This question already has an answer here:

I have got the following datetime from an API: 1395401384298

I am guessing it is in epoch miliseconds time (it should be one day in 2014) How can i convert it into a more readable String? I have been looking into DateString[] (https://reference.wolfram.com/mathematica/ref/DateString.html) with no sucess.

share|improve this question

marked as duplicate by Pickett, rasher, bobthechemist, Sjoerd C. de Vries, Michael E2 Mar 26 at 23:57

This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.

2 Answers 2

up vote 3 down vote accepted

The epoch starts from jan 01 1970, so you can do: to = AbsoluteTime[{1970, 1, 1, 0, 0, 0.`}];

DateString[1395858190 + to]

Wed 26 Mar 2014 18:23:10

From http://www.epochconverter.com/

GMT: Wed, 26 Mar 2014 18:23:10 GMT

share|improve this answer

It is in the very fa future :) DateString[1395401384298] "Tue 5 Jul 46118 23:38:18"

Adding a dot brings closer: DateString[1395401384.298] "Tue 21 Mar 1944 11:29:44"

So check the data you have received. János

share|improve this answer
    
That is the wrong answer i am getting. The right answer is GMT: Fri, 21 Mar 2014 11:29:44 GMT (you can check it in epochconverter.com ) –  Trollkemada Mar 26 at 17:46

Not the answer you're looking for? Browse other questions tagged or ask your own question.