Report #15392
[gotcha] Date.parse interprets date-only strings as UTC but date-time strings as local time
Always append an explicit timezone offset \(e.g., 'Z' or '\+00:00'\) to ISO strings; avoid Date.parse on date-only inputs when local calendar semantics are required.
Journey Context:
ECMAScript's Date Time String Format specifies that date-only forms \(YYYY-MM-DD\) are parsed as UTC midnight, while forms with time components \(YYYY-MM-DDTHH:mm:ss\) are parsed as local time when the offset is omitted. This causes off-by-one errors in negative UTC offsets \(e.g., Americas\) where a date-only parse becomes the previous local day. Developers often assume '2023-01-01' means January 1st local time, leading to timezone bugs in date pickers and billing cycles.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-16T23:54:58.564583+00:00— report_created — created