Time Utilities

ISO Week Number

Calculate the ISO week, weekday, day of year, and quarter for a date.

ISO week number and date details
ISO 8601 · Weeks start on Monday
Calculated details
2026-11-02 → 2026-11-08
2026-W45ISO week
TuesdayWeekday
307Day of year
Q4Quarter
Week starts
2026-11-02
Week ends
2026-11-08
The calendar year containing this date is not a leap year.

ISO Week Number

Calculate ISO 8601 week information. Weeks start on Monday, and week 1 contains the year's first Thursday, so dates near a year boundary can belong to the adjacent ISO week-year.

Output

  • ISO week-year and week number
  • Monday and Sunday boundaries
  • Weekday, day of year, quarter, and leap-year state

An ISO week lookup turns one calendar date into its ISO 8601 week identifier: a week-year plus a number from 01 to 53, together with the Monday-to-Sunday span that week covers. It also reports weekday, day of year, quarter and leap-year state, which is what sprint boards, weekly reports and European billing periods are keyed on.

Shifting to the week’s Thursday fixes the week-year

ISO 8601 defines week 1 as the week containing the year’s first Thursday, which is the same week that contains 4 January. This tool reaches it by moving the input to its own Thursday first: date + (4 - isoDay), where isoDay is getUTCDay() with Sunday remapped from 0 to 7. Whatever year that Thursday falls in becomes the week-year, and the number is the Thursday’s day-of-year divided by 7 and rounded up. 31 December 2026 is itself a Thursday and day 365, so ceil(365 / 7) yields 53. Because only the Thursday votes, 1 January 2027 reports 2026-W53, and Monday 30 December 2024 reports 2025-W01 while still sitting in 2024.

The week label uses the ISO year, the other tiles do not

Only the week label comes from the ISO week-year. Day of year, quarter and the leap-year line are all derived from the calendar year of the input date. On 2027-01-01 the label reads 2026-W53, yet day of year is 1, quarter is Q1, and the leap check inspects 2027 rather than 2026. Each field is right on its own terms, but the four tiles cannot be combined into a statement like "day 1 of ISO year 2026". If you export a schedule keyed by week-year, use the Monday and Sunday dates rather than the ordinal day, because the displayed week can reach into the next calendar year: 2026-W53 runs from 2026-12-28 to 2027-01-03.

UTC-only arithmetic, and a validation that refuses rollover

The input is parsed as YYYY-MM-DDT00:00:00Z and every later step uses UTC setters and getters, so neither the machine’s offset nor a daylight-saving change can shift the weekday. Day arithmetic divides by 86400000, an assumption that only holds while every day is 24 hours long; in local time the spring-forward day is 23 hours and the rounding breaks. Input is also checked twice: a pattern anchored at both ends (four digits, hyphen, two, hyphen, two) and a round-trip comparison that serializes the parsed date back and matches it against the typed text. A date like 2026-02-30 normalizes to 2 March, fails that comparison, and hides the result panel instead of printing a corrected date.

Worked example

A week label that disagrees with its own calendar year

Input
2027-01-01
Output
ISO week: 2026-W53
Weekday: Friday
Day of year: 1
Quarter: Q1
Week starts: 2026-12-28
Week ends: 2027-01-03

1 January 2027 is a Friday, so its Thursday is 2026-12-31: the week-year is 2026 and the number is 53, the final week of a 53-week ISO year. Day of year and quarter still read 1 and Q1 because they are counted inside 2027. The span itself crosses the year boundary, running seven days from Monday 2026-12-28 to Sunday 2027-01-03.

Limits and pitfalls

  • Only the ISO 8601 rule is computed; there is no Sunday-start or "week 1 contains 1 January" mode, so boundary dates differ by one week from Excel’s default WEEKNUM and from US-style calendars.
  • The input must be a full four-digit-year YYYY-MM-DD: the pattern is anchored at both ends and the parsed value must serialize back to the same string, so 2026-2-3, 26-02-03 and 2026-02-30 are rejected rather than corrected.
  • There is no time-of-day or time-zone field: the date is pinned to UTC midnight, so it describes a calendar day, not an instant, and a raw timestamp must first be reduced to a date in the zone that matters.
  • Day of year, quarter and the leap-year line belong to the Gregorian year, not the ISO week-year; 2021-01-01 shows 2020-W53 next to a day of year of 1, and those numbers are not offsets inside 2020.
  • One date is processed per lookup, with no range, list or CSV input, so turning a whole quarter into a week index means repeating the lookup week by week.

Related tools

When this lookup is the right stop, and when it is the wrong one

What you have to settleThis pageWhat actually settles it
One date, and you also need the Monday and Sunday it sits inEnter 2026-12-31 and the label 2026-W53 arrives together with its span, 2026-12-28 to 2027-01-03, plus weekday, day of year, quarter and leap state — one date per lookup, no time field, no offset.A spreadsheet needs two formulas for the same answer: =ISOWEEKNUM(A2) (Excel 2013 and later) for the number, =A2-WEEKDAY(A2,3) for the Monday, plus six for the Sunday. Excel has no ISO-year function at all, so a cell reading 53 never says which year that 53 belongs to.
A column of three hundred datesThe input is a single date field. There is no list, range or CSV mode, so a quarter of daily rows means three hundred separate lookups and three hundred copied labels.Script it: datetime.date.fromisoformat(s).isocalendar() returns (iso_year, week, weekday) as a named tuple whose first field is the ISO year, not the calendar year — the value strftime("%V") alone will not hand you.
Your team counts weeks from Sunday, or calls the week of 1 January week 1ISO 8601 only, hard-wired: Monday is day 1, and week 1 is the week holding the year’s first Thursday. There is no return-type switch, so a US-style question gets an ISO-style answer.Excel WEEKNUM(A2,1) starts on Sunday; WEEKNUM(A2,2) starts on Monday but still calls the week containing 1 January week 1. The divergence is boundary-only: 2027-01-01 is 2026-W53 here and 1 under WEEKNUM(DATE(2027,1,1),2).
A value a build script can readNothing here exits or prints to a shell: the label exists on screen for a person to copy, so it is a check you make, not a step a pipeline can gate on.date -u -j -f "%Y-%m-%d" "2026-12-31" +%G-W%V on macOS/BSD, date -u -d 2026-12-31 +%G-W%V on GNU, both print 2026-W53. Never substitute %W or %U: those are 00-based, so 2021-01-01 prints 2021-W00.
The date is really a UTC timestampThe value is a calendar date pinned to T00:00:00Z, so it cannot tell you which day an instant was in Tokyo. Reduce the instant to a local date first.Send the epoch through the timestamp converter at the target offset, then paste the resulting date here. One instant, two labels: 2025-12-28T23:30Z is 2025-W52 in UTC, but 2025-12-29 in JST, which is 2026-W01.
How many weeks apart two dates areTwo lookups, and subtracting the numbers breaks the moment the week-years differ: 2025-W52 to 2026-W01 is one week forward, which a naive subtraction reports as −51.Take the day difference from the date calculator and divide by 7. Pick endpoints on the same weekday so the remainder is zero; a remainder means you compared a Monday with a Wednesday, not that the weeks are fractional.

ISO week-years 2020–2032: length, first Monday, closing Sunday

ISO yearWeeks in itMonday that opens W01Sunday that closes the last week
2020532019-12-302021-01-03
2021522021-01-042022-01-02
2022522022-01-032023-01-01
2023522023-01-022023-12-31
2024522024-01-012024-12-29
2025522024-12-302025-12-28
2026532025-12-292027-01-03
2027522027-01-042028-01-02
2028522028-01-032028-12-31
2029522029-01-012029-12-30
2030522029-12-312030-12-29
2031522030-12-302031-12-28
2032532031-12-292033-01-02

A week-year has 53 weeks exactly when 1 January is a Thursday, or when it is a leap year whose 1 January is a Wednesday — 2026 and 2032 are the first kind (1 January on a Thursday), 2020 the second. To place any date, move it to its own Thursday (+4 − isoDay, with Sunday counted as 7): that Thursday’s calendar year is the week-year and ceil(dayOfYear / 7) of the same Thursday is the number. The last two columns are exactly what the page prints as week starts / week ends for any date inside that ISO year, and the closing Sunday may fall in the following January — ISO 2026 ends on 2027-01-03, which is why 2027-01-01 reads 2026-W53.

Frequently Asked Questions

Why does the same date have different week numbers in different systems?
Three competing definitions: ISO 8601 (weeks start Monday; week 1 contains the first Thursday), the North American convention (weeks start Sunday; week 1 contains January 1), and plain 7-day counting. Project management and European business use ISO; US media often use the American style — the tool defaults to ISO with a switch.
What is the ISO week-year boundary trap?
December 29–31 can belong to week 1 of the next ISO year, and January 1–3 to week 52/53 of the previous one. When coding, key schedules by "ISO week-year + week", never calendar year + week, or cross-year planning slips by a week.
Can a year really have 53 weeks?
Yes — an ISO year has 53 weeks when January 1 is a Thursday, or when a leap year starts on Wednesday (2020 and 2026 are examples). Weekly reports and planning templates must handle 53-week years or the end of the year goes missing.

Content reviewed: