Issue #7445 has been updated by tadf (tadayoshi funaba). but you can't preserve offset with mktime(3). if you want substring which denote %z, you can call _strptime. DateTime._strptime('0 +0100', '%s %z') #=> {:seconds=>0, :zone=>"+0100", :offset=>3600} you told about C's stdlib. why not talk about ruby's Time? Time is based on stdlib. why not want it with Time? ---------------------------------------- Bug #7445: strptime('%s %z') doesn't work https://bugs.ruby-lang.org/issues/7445#change-39783 Author: felipec (Felipe Contreras) Status: Assigned Priority: Low Assignee: tadf (tadayoshi funaba) Category: lib Target version: Next Major ruby -v: ruby 1.9.3p327 Backport: See: ruby -e "require 'date'; p DateTime.strptime('0 +0100', '%s %z').strftime('%s %z')" The timezone is ignored. -- http://bugs.ruby-lang.org/