Need help with LatLongToTimezone?
Click the “chat” button below for chat support from the developer who created it, or find similar developers for support.

About the developer

139 Stars 33 Forks MIT License 100 Commits 11 Opened issues


Lat/long to timezone mapper in Java. Does not require web services or data files - just pure Java or Swift.

Services available


Need anything else?

Contributors list


Lat/long to timezone mapper in Java and Swift and C#. Does not require web services or data files.

The "lat/long to timezone polygon mapping" is hardcoded, and we hope this rarely changes, but the changes to offsets and daylight savings changeover dates etc. (which are more frequent) are taken care of by your system libraries and so these are automatically kept up-to-date. From time to time, someone updates the files with the latest timezone polygons, but these rarely change...I think the most recent change is the Crimean peninsular.

99% of people using this project just need the one file:







# Podfile

pod 'LatLongToTimezone', '~> 1.1'

In the

directory, type:
$ pod install


Add this to

github "drtimcooper/LatLongToTimezone" ~> 1.1
$ carthage update


For Swift 2.3 and earlier, use version 1.0.4 of the Podspec. For Swift 3 to 4.1, use version 1.1.3 of the Podspec. For Swift 4.2 or later, use the latest version.


In your code, you can do

import LatLongToTimezone

let location = CLLocationCoordinate2D(latitude: 34, longitude: -122) let timeZone = TimezoneMapper.latLngToTimezone(location)

Android Studio (Kotlin)

  • Create a Java class calls
  • Copy & Paste this file
  • Remove
    package com.skedgo.converter;
    and replace it with your package (Don't forget the semicolon)

Add in your

val resultTimeZone = TimezoneMapper.latLngToTimezoneString(YOUR_LATITUDE, YOUR_LONGITUDE)
Log.i("", resultTimeZone)

Now you should see the TimeZone (open


We use cookies. If you continue to browse the site, you agree to the use of cookies. For more information on our use of cookies please see our Privacy Policy.