http://stackoverflow.com/questions/22360332/time-conversion-between-ruby-on-rails-and-javascript-vice-versa Ruby epic_time = Time.zone.now.to_f * 1000 JavaScript const epic_time = <time from ruby> var d = new Date(1394648309130.185)