WebKit/Chrome Timestamp Converter

Convert WebKit/Chrome timestamps to human readable date & Unix time

This timestamp format is used in web browsers such as Apple Safari (WebKit), Google Chrome and Opera (Chromium/Blink). It's a 64-bit value for microseconds since Jan 1, 1601 00:00 UTC.

The current WebKit timestamp is 13140237281000000.

 
 

Programming routines

Python

import datetime
def date_from_webkit(webkit_timestamp):
    epoch_start = datetime.datetime(1601,1,1)
    delta = datetime.timedelta(microseconds=int(webkit_timestamp))
    print epoch_start + delta

inTime = int(raw_input('Enter a Webkit timestamp to convert:'))
date_from_webkit(inTime)

Example on Pastebin

 

Thanks to dpcnull.

Pages

Date and Time
Week numbers
Weeks by year
Day numbers
Days by year
Years/leap years
Calculate difference
   between two dates


More
Comments & questions
Este sitio en Español
Related cookbooks
Charset Tools



Follow us