Skip to content

Main content

Date: Timestamp Offset Negative Zero Check Tool

Distinguish RFC3339 unknown-local-offset -00:00 from known zero offset Z/+00:00 in one validated offset token.

Loading tool…

Description

Distinguish known zero UTC offset from unknown local offset.

A fixed UTC offset differs from a named timezone whose rules can vary by date. A zone-like label or signed-zero offset also carries metadata that a numeric minute total alone cannot express.

Distinguish known zero UTC offset from unknown local offset.

When to use this tool

Use Date: Timestamp Offset Negative Zero Check when inspecting a supplied offset or timezone annotation.

How to use the tool and how it works

  1. Enter offsetToken. Use the units and conventions below.
  2. Run the tool. Correct any format, range, or cross-field input error before interpreting the output.
  3. Read result. Expand result to inspect the returned fields.

Distinguish known zero UTC offset from unknown local offset. Accept Z or ±HH:MM with bounded components; unknownLocalOffset is exact -00:00 and knownZeroOffset is Z or +00:00.1

RFC 3339 distinguishes an unknown local offset from known UTC and restricts leap-second notation to appropriate actual time contexts; lexical parsing does not verify those contexts.2

Input fieldMeaning and unitsAccepted input
offsetTokenOffset TokenRequired. Text. Implementation limit: 8192 Unicode code points and 16384 UTF-16 code units.
Output fieldInterpretationReturned shape
resultReturned object; expand its named members below.Required. Object.
result.unknownLocalOffsetTrue for -00:00, indicating unknown local offset under RFC 3339.Calculated result member: boolean.
result.knownZeroOffsetTrue for recognized zero-offset spellings that do not carry the negative-zero unknown marker.Calculated result member: boolean.
json
{
  "input": {
    "offsetToken": "-00:00"
  },
  "output": {
    "result": {
      "unknownLocalOffset": true,
      "knownZeroOffset": false
    }
  }
}

Limitations and assumptions

  • Other nonzero offsets make both flags false; no local zone or DST context is known.
  • Outputs are nested inside result. Inputs must satisfy both the field types and the cross-field conditions above. Invalid input causes an error; a successful false flag or documented placeholder is a different result.

Alternative or Complementary methods

Use an authoritative timezone database and complete timestamp context to resolve an actual local time or day.

References

  1. Calculation and input contract: date/timestamp-offset-negative-zero-check — tool.io

  2. RFC 3339: Internet timestamps — RFC Editor

Similar or alternative tools