Dates Display in Unix Epoch Time Instead of Date or Datetime

Published: 02 May 2013
Last Modified Date: 15 Dec 2017


Date field displays Unix epoch time instead of the date or datetime format.


Tableau Desktop


Option 1: Convert to a Date Field

  1. Select Analysis > Create Calculated Field.
  2. Type the following into the Formula field, and then click OK:
    DATE(DATEADD('second', INT([Unix Date]), #1970-01-01#))

Option 2: Convert to a Datetime Field

  1. If the date is interpreted as a string instead of a number value, right-click the field and select Change Data TypeNumber.
  2. Select Analysis > Create Calculated Field.
  3. Type the following into the Formula field, and then click OK:
    DATEADD('hour',-7,(Date("1/1/1970") + ([Unix Date]/86400)))
    • Important: -7 will need to be  adjusted based on your timezone (Unix time corresponds to UTC, therefore -7 corresponds to Pacific Standard Time).
Note: Both the above options assume that the date field is in seconds. If the field is in milliseconds (which is the standard for Unix), then it will need to be converted before using the following options. To do so, please divide the field by 1000.


The data source is using Unix epoch time. Tableau Desktop does not automatically convert this time format into a date or datetime format.
Did this article resolve the issue?