ISO Week Number
ISO-8601 week of the year (weeks start on Monday).
Formula
Variables
Example
A year has 52 weeks, or 53 when it starts on a Thursday
How it works
This formula assigns an ISO 8601 week number by counting complete 7-day blocks from the start of the year after first correcting for the fact that ISO weeks begin on Monday. The term d_o - w_d + 10 shifts the date so that the Thursday of the current week determines the week year, which is why dates near New Year’s can belong to the previous or next ISO week year. The floor then removes any partial week and turns the adjusted day count into a whole week index.
When to use it
Use this when you need the ISO week number for reporting, payroll, logistics, database queries, or anything that groups dates into Monday-to-Sunday weeks. It is especially useful around year boundaries, where the ISO week may differ from the calendar year.
Worked example, step by step
Example date: 2026-01-01 Step 1: Find the ordinal day of the year. d_o = 1 Step 2: Find the ISO weekday. 2026-01-01 is a Thursday, so w_d = 4 Step 3: Substitute into the formula. W = floor((d_o - w_d + 10) / 7) W = floor((1 - 4 + 10) / 7) W = floor(7 / 7) W = floor(1) W = 1 Final answer: the ISO week number is 1.
Common mistakes to avoid
- Using Sunday-based weekday numbering instead of ISO Monday=1 to Sunday=7
- Assuming the ISO week number always matches the calendar year
- Forgetting that dates at the start or end of January can belong to week 52 or 53 of the adjacent ISO week year
Did You Know?
ISO week 1 is the one containing the year's first Thursday, so early-January days can belong to the previous year's week 52 or 53.
Share this formula
More in Time & Calendar
View allLeap Year Rule
BasicTests whether a Gregorian year has 366 days.
Clock Hand Angle
BasicAngle between the hour and minute hands of an analog clock.
Zeller's Congruence
AdvancedFinds the day of the week for any Gregorian date.
Day of the Week from a Birthdate
IntermediateGauss's weekday formula — find which day of the week any birthdate fell on.
Julian Day Number
AdvancedContinuous day count used by astronomers to compare dates.
Days Between Two Dates
IntermediateNumber of days separating two calendar dates.