Developer tools · Unix timestamp converter
Time zones are not offsets: the IANA tz database and why it matters
· Background
timestamps time-zones browser-apis
An offset is a number; a time zone is a history of numbers and the rules for when they change. This post explains the difference, introduces the IANA tz database that encodes it, and shows why converters rely on it for the local reading.
The meeting that moved by an hour — a stored offset of +02:00 that was right in July and wrong in December
A fixed `+02:00` saved beside a July meeting can be a faithful reading for that instant and still fail as a rule for December. The offset is one result; the zone is the rule context capable of producing results at different dates. Storing one as though it were the other freezes a snapshot.
ToolAcre’s local row asks Intl to format each Date and requests a short numeric offset. It does not add a configuration constant to the epoch. That design allows the environment’s applicable rule to influence every instant separately.
Offset versus zone — a fixed distance from UTC versus a named region with DST rules and a history of changes
An offset states how far a rendered clock is from UTC at one instant. A named region can carry a sequence of offset rules and historical changes. The epoch itself carries neither. These concepts should occupy separate fields when an application needs both an event and a place-based schedule.
For an immutable event, storing the instant may be enough. For “open at 09:00 in this region every day,” retain the named zone because future instances must be resolved from wall time. Reusing yesterday’s offset treats a dynamic rule as a permanent numeric property.
The IANA tz database — Area/City names, why it is a record of political decisions, and how often it is updated
The workbook named the IANA database, political provenance and update frequency. The implementation reports an IANA-style zone name from `resolvedOptions()` but does not expose a database version, update schedule or source package. Those details are not asserted here.
This limitation affects reproduction. If old-date output differs between machines, record the zone string and platform versions; do not claim which rule set is newer from the clock alone. A named zone improves the question, but the converter is not a time-zone data inspector.
Applications that need reproducible historic output should control their zone-data dependency and test representative dates. Relying on an unspecified browser environment delegates that reproducibility.
Named-zone rule provenance and update cadence are not exposed by this implementation
ToolAcre asks the browser for its local zone and formats through Intl. The repository does not establish whether rules came from the operating system, browser bundle or another runtime component. It catches failure and falls back safely rather than exposing that internal architecture.
Consequently, “local” means the environment selected by the browser at conversion time. Changing the device setting can change output without changing the epoch. For audit trails, preserve UTC and the raw count; use local display as context rather than canonical storage.
The fallback to ISO on formatter failure preserves an instant but loses the requested local presentation. Consumers should treat that as reduced display context, not a changed date.
The browser selects and formats its local zone; the source of its rules is not asserted
Choose two UTC instants six months apart, such as `2025-01-15T12:00:00Z` and `2025-07-15T12:00:00Z`, convert them to seconds, and inspect the local rows on one device. Record whether the numeric offset differs. The observation is valid for the displayed zone and environment.
The workbook prescribed Europe/Berlin offsets, but those named-zone rules were not read from implementation. This reproducible exercise avoids an unsupported table while teaching the same distinction: one zone query, two instants, and potentially two offset results.
If the offsets match, the observation is still informative: that configured zone did not expose a seasonal difference at those chosen instants in that environment.
Worked example: observe one browser zone at two dates instead of hard-coding Berlin rules
The panel requests `timeZoneName: "shortOffset"`, which favors a numeric relationship such as GMT+1 over a regional abbreviation. That choice reduces reliance on labels whose meaning can vary by context, although exact Intl formatting remains platform output.
For stored data, use canonical zone identifiers defined by the application’s chosen library rather than display abbreviations. A user-facing short label can be helpful, but it should not become the key that reconstructs a future schedule.
Numeric offsets remain unambiguous as arithmetic at one instant. Their limitation is missing rule identity, not an inability to map that one clock reading back to UTC.
Abbreviations are avoided in stored data; the formatter requests a short numeric offset
Recurring future scheduling needs gap, overlap and policy handling that this converter does not provide. It starts with a resolved date or epoch and renders it. It does not choose between two repeated local times or repair a nonexistent one.
Use a zone-aware scheduling library whose behavior is tested for your requirements, then inspect resolved occurrences here if helpful. Separating resolution from display keeps a simple converter from becoming an accidental scheduler with undefined edge policy.
The scheduler’s output can then be stored as an epoch for execution while retaining the zone and original wall-time intent for future recalculation or explanation.
Takeaway: store instants as epochs, store places as zone names — and how the Unix timestamp converter uses your browser's zone for the local reading
Store instants as explicit epoch units or canonical UTC strings, and store named zones when the place itself matters. An offset can accompany an output for explanation, but it is not a substitute for either field. ToolAcre’s UTC and local rows demonstrate that separation.
When a local result surprises you, check zone label, instant and offset before changing data. A fixed-offset patch may make one date look right and another wrong. The durable model keeps the event stable and lets a verified zone rule supply its clock face.
This model also supports travel: a user can view one stored instant in a new local zone without rewriting the event or losing its original scheduling context.