>>> import time >>> date = 'Sep 26, 2016 12:00:00 AM' >>> time.strptime(date,'%b %d, %Y %I:%M:%S %p') time.struct_time(tm_year=2016, tm_mon=9, tm_mday=26, tm_hour=0, tm_min=0, tm_sec=0, tm_wday=0, tm_yday=270, tm_isdst=-1)