Calculation methodology
Every tool and generated table uses the same module in src/lib/iso-week.mjs. It treats user-entered dates as civil calendar dates and performs calendar arithmetic in UTC to avoid daylight-saving shifts.
Date to ISO week
- Find the Monday of the date's week.
- Move to that week's Thursday to determine the ISO year.
- Find the Monday of the week containing January 4.
- Count complete seven-day periods to obtain the week number.
ISO week to dates
The Monday of week 1 is the Monday in the week containing January 4. Six days are added to obtain Sunday. The week number is rejected if it is above the final week containing December 28.
Current date and timezone
Static HTML is generated with a UTC date so the answer is readable without JavaScript. In the browser, Intl.DateTimeFormat extracts the civil date in the visitor's resolved IANA timezone and updates the current-week display. The timezone name is always shown.
Tests
Automated tests cover ordinary dates, December 31 and January 1, dates assigned to adjacent ISO years, week 53, leap day, timezones on opposite sides of midnight, invalid weeks and ranges crossing New Year. The site check also verifies canonical URLs, titles, H1 counts, local links, sitemap entries and forbidden placeholder links.
Source
The rules follow ISO's description of ISO 8601. The standard record is ISO 8601-1:2019.