From: Eric Wong Date: 2014-08-15T00:46:40+00:00 Subject: [ruby-core:64372] Re: [ruby-trunk - Bug #10135] [Open] Time.at is inaccurate I didn't know this before, but I investigated this and see Time.at may take a second argument for microseconds. You may try: Time.at(seconds, microseconds_with_frac) -> time n = 1381089302195 p Time.at(n / 1000, (n % 1000) * 1_000).strftime('%3N')