A shapefile of Time Zones originally maintained by http://efele.net/maps/tz/world/
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
antarctica
canada
fips10c
fips10s
world
README.md

README.md

#Introduction#

Eric Muller (http://efele.net/maps/tz/world/) originally created the awesome Shape file of time zones. This essentially allows you to look up a time zone based on geographic coordinates (lat/long).

Why would you want to do this?

  • You can convert times/dates displayed on your website in the users local time
  • You can use it as part of a validation scheme (make sure the users computer time zone is the same as you expect, and they are not using a proxy or VPN)
  • Notify a user if their local time zone setting may be incorrect
  • Show a cool map of what the world looks like with time zone boundaries instead of political ones.

I decided to fork his work so that I can keep the data up to date on my own cycle. As well, I have plans to turn this into a shared library that can be used elsewhere.

#The Data# The shape file contains just one field. The "name" of the time zone as found in IANA's Time Zone Database (http://www.iana.org/time-zones). This means that you will have to work with strings such as "America/Toronto" or "Australia/Sydney".

It's up to you to then convert that time zone name into a proper numerical offset from UTC. This can usually be done with your language of choice and your operating systems local version of the zoneinfo database.

##Update Frequency## I try to update the data as soon as IANA does. They announce updates via their mailing list, and versions are numbered based on the year. So for example: 2014b would be the second version released in 2014. It's usually updated around once a month.

#Gimme my shapefile!# You can find the latest version of the shape file in this repo (in the output subdirectory):

#Contact# Please feel free to contact me (me@blakecrosby.com) if you have any questions. I encourage pull requests to update the database if you find any errors.