Does anyone know where can I get US zip codes with time zones?

Hi,

we ask user for his zip code and currently we also ask for this time zone (only US). It's a bit redundant, so I'd like to figure out user's time zone based on his zip code.

The problem is that all services I've seen that provide such data, provide only time offset and daylight savings flag for each zip code. I'd rather have Rails time zone or anything that I can easily map to it :slight_smile:

Or maybe having offset and daylight saving time flag is enough to do the mapping myself?

Thanks

we ask user for his zip code and currently we also ask for this time zone (only US). It's a bit redundant, so I'd like to figure out user's time zone based on his zip code.

The problem is that all services I've seen that provide such data, provide only time offset and daylight savings flag for each zip code. I'd rather have Rails time zone or anything that I can easily map to it :slight_smile:

Or maybe having offset and daylight saving time flag is enough to do the mapping myself?

Should be.

I've used U.S. 5 Digit ZIP Code Database - Updated Nov 1, 2023 on several projects.

zip_code | city | state | time_zone | day_light_savings

Is it possible that 2 regions in US at any time of year have the same time offset, both are in daylight savings time, but actually have different time zones? If not, then it should be easy to map this data to Rails time zones.

szimek wrote:

Is it possible that 2 regions in US at any time of year have the same
time offset, both are in daylight savings time, but actually have
different time zones? If not, then it should be easy to map this data
to Rails time zones.

No it is not possible. But there are places in the US (like Arizona) that do not observe DST so that Arizona has the same offset as California etc. in the summer but in the winter it does not.