ISO Week Numbers Explained
Understand ISO week numbers, ISO week years, Monday-based weeks, Week 1 rules, and common date calculation pitfalls.
ISO week numbers are a standardized way of organizing dates into numbered weeks. Instead of simply dividing a calendar year into groups of seven days, the ISO 8601 week-date system defines exactly when a week starts, which week is Week 1, and how dates near New Year's Day should be assigned.
ISO weeks are widely useful in business reporting, project planning, scheduling, manufacturing, logistics, finance, analytics, and software development. They make it possible to refer to a week consistently across different countries and systems.
What Is an ISO Week Number?
An ISO week number identifies the position of a week within an ISO week-based year. ISO weeks are numbered from 1 through 52, although some ISO years contain a 53rd week.
Unlike a traditional calendar year, an ISO week-based year does not necessarily begin on January 1. The first few days of January can belong to the final ISO week of the previous year, while the final days of December can belong to Week 1 of the next ISO year.
| ISO Component | Rule |
|---|---|
| Week starts | Monday |
| Week ends | Sunday |
| Week 1 | The week containing January 4 |
| Alternative Week 1 rule | The week containing the year's first Thursday |
| Weeks per ISO year | 52 or 53 |
When Does an ISO Week Start?
An ISO week always starts on Monday and ends on Sunday. This differs from some calendar and regional conventions where Sunday is considered the first day of the week.
For example, if Monday is January 5, the ISO week containing that date runs from Monday, January 5 through Sunday, January 11. Every date within that seven-day period has the same ISO week number and ISO week year.
What Is ISO Week 1?
ISO Week 1 is the first ISO week of an ISO week-based year. It is the week that contains January 4. The same rule can be expressed as the week containing the first Thursday of the calendar year.
Another useful way to think about the rule is that ISO Week 1 is the first week with at least four days in the new calendar year. This prevents a short partial week at the beginning of January from being treated as a complete first week.
| Rule | Meaning |
|---|---|
| Contains January 4 | The week is ISO Week 1 |
| Contains the first Thursday | The week is ISO Week 1 |
| Has at least four days in the new year | The week is ISO Week 1 |
| Starts on Monday | All ISO weeks begin on Monday |
Why Can January Belong to the Previous ISO Year?
Because ISO Week 1 is determined by the first Thursday rather than simply January 1, some dates at the beginning of January can belong to the final ISO week of the previous ISO year.
For example, if January 1 falls on a Friday, Saturday, or Sunday, the days before the first Monday-based ISO Week 1 can still belong to the previous ISO week-based year. The calendar year and ISO week year therefore do not always change at the same moment.
Calendar date: January 1
ISO week year: Previous year
ISO week: 53 or 52This is one of the most common sources of confusion when developers format dates using ISO week numbers. A date can have a calendar year of one value and an ISO week year of another.
Why Can December Belong to the Next ISO Year?
The reverse situation can also occur near the end of December. If December 29, 30, or 31 falls in the Monday-to-Sunday week that is classified as ISO Week 1 of the following ISO year, those dates belong to the next ISO week-based year.
For this reason, software that displays an ISO week should generally calculate both the ISO week number and ISO week year. Using the ordinary calendar year together with the ISO week number can produce misleading labels around New Year's Day.
ISO Week Date Format
An ISO week date can be represented using the ISO week-based year, week number, and weekday. The common notation uses the letter W before the week number.
2026-W35-5In this example, 2026 is the ISO week-based year, W35 represents Week 35, and 5 represents Friday because Monday is weekday 1 and Sunday is weekday 7.
| ISO Weekday | Day |
|---|---|
| 1 | Monday |
| 2 | Tuesday |
| 3 | Wednesday |
| 4 | Thursday |
| 5 | Friday |
| 6 | Saturday |
| 7 | Sunday |
How Many Weeks Are in an ISO Year?
An ISO year contains either 52 or 53 complete weeks. A 52-week ISO year contains 364 days, while a 53-week ISO year contains 371 days.
A 53rd week is necessary in certain calendar configurations so that every ISO week remains a complete Monday-to-Sunday period while preserving the Week 1 rules. Not every calendar year has an ISO Week 53.
When Does an ISO Year Have 53 Weeks?
An ISO year has 53 weeks when the calendar configuration causes the year to contain 53 complete ISO weeks. A practical rule is that an ISO year has 53 weeks when January 1 is a Thursday, or when January 1 is a Wednesday in a leap year.
The equivalent end-of-year condition is that December 31 falls on a Thursday, or on a Friday in a leap year. These rules are useful when implementing a week-numbering algorithm.
| Condition | ISO Year Has 53 Weeks? |
|---|---|
| January 1 is Thursday | Yes |
| January 1 is Wednesday and the year is a leap year | Yes |
| December 31 is Thursday | Yes |
| December 31 is Friday and the year is a leap year | Yes |
| Other configurations | Usually 52 weeks |
ISO Weeks and Leap Years
Leap years can affect ISO week numbering because they contain an additional calendar day. A leap year has 366 days rather than 365, which changes the weekday on which the following year begins and can affect whether an ISO year contains 52 or 53 weeks.
However, being a leap year does not automatically mean that the ISO year contains 53 weeks. The weekday configuration must also satisfy the relevant ISO week-year rule.
ISO Week Number vs Calendar Week Number
The term calendar week can mean different things depending on the country, organization, application, or software library. Some systems start weeks on Sunday, some start on Monday, and some define Week 1 as simply the week containing January 1.
ISO week numbers avoid much of this ambiguity by defining a precise standard: Monday is the first weekday, Sunday is the seventh, and Week 1 is the week containing January 4.
| Feature | ISO Week System | Generic Calendar Week |
|---|---|---|
| First weekday | Monday | Depends on convention |
| Week 1 | Week containing January 4 | Depends on convention |
| Possible weeks | 52 or 53 | Depends on convention |
| ISO year | May differ from calendar year | Often follows calendar year |
How to Calculate an ISO Week Number
A correct ISO week calculation first determines the weekday of the date and then identifies the Monday-based week containing it. The calculation must also determine which ISO week-based year that week belongs to.
A common mathematical approach is to find the Thursday belonging to the same ISO week. Because every ISO week contains exactly one Thursday, that Thursday determines the ISO week year. The week number can then be calculated relative to the first ISO week of that year.
function getISOWeek(date) {
const d = new Date(Date.UTC(
date.getFullYear(),
date.getMonth(),
date.getDate()
));
const day = d.getUTCDay() || 7;
d.setUTCDate(d.getUTCDate() + 4 - day);
const yearStart = new Date(
Date.UTC(d.getUTCFullYear(), 0, 1)
);
const week = Math.ceil(
((d - yearStart) / 86400000 + 1) / 7
);
return {
year: d.getUTCFullYear(),
week,
};
}Date arithmetic is sensitive to time zones and daylight-saving transitions. For production applications, it is often safer to use a well-tested date-time library or a platform API that explicitly supports ISO week calculations rather than relying on hand-written date arithmetic.
ISO Week Numbers in Business and Reporting
ISO week numbers are particularly useful when organizations need consistent weekly reporting. A report can refer to values such as 2026-W35 instead of using an ambiguous label like Week 35.
Because the ISO week year is included, reports can distinguish between the final weeks of one ISO year and the first weeks of the next. This is especially useful for annual dashboards, financial analysis, production schedules, and operational metrics.
- Weekly sales and revenue reports.
- Project and sprint planning.
- Manufacturing and production schedules.
- Employee and workforce reporting.
- Logistics and delivery planning.
- Recurring maintenance schedules.
- Analytics grouped by week.
ISO Weeks in Software Development
Developers may need ISO week numbers when generating reports, grouping records, creating calendar interfaces, processing recurring jobs, or exchanging dates between systems. The important distinction is that an ISO week is not simply a number attached to a calendar year.
For example, a database field containing an ISO week should usually preserve both the ISO year and week number. Storing only 1 through 53 is ambiguous because Week 1 occurs every year and Week 53 does not always exist.
ISO week key:
2026-W01
2026-W02
2026-W03
...
2026-W52Common ISO Week Number Mistakes
- Assuming every ISO year starts on January 1.
- Assuming every week starts on Sunday.
- Defining Week 1 as the week containing January 1.
- Ignoring the ISO week year near New Year's Day.
- Assuming every ISO year has exactly 52 weeks.
- Calculating the week number by simply dividing the day of the year by seven.
- Using the calendar year together with an ISO week number without checking the ISO week year.
- Assuming that local calendar-week conventions are equivalent to ISO 8601.
ISO Week Numbers and Date Differences
ISO week numbers are useful for grouping dates into weeks, but they should not be confused with measuring elapsed time. Two dates can have different week numbers while being only a few days apart, especially around the boundary between ISO years.
Likewise, subtracting ISO week numbers is not a reliable way to calculate the number of weeks between arbitrary dates. Week numbers reset when the ISO year changes, and some ISO years contain 53 weeks.
ISO Week Numbers and Working Days
ISO weeks can also be useful when organizing working-day calculations. Since ISO defines Monday through Friday as weekdays 1 through 5, applications can use the ISO weekday numbering alongside business calendars and holiday rules.
However, ISO week numbering does not define which days are business holidays or working days. Those rules depend on the country, organization, employment agreement, or application being modeled.
ISO Week Numbers: Key Takeaways
- ISO weeks start on Monday and end on Sunday.
- ISO Week 1 is the week containing January 4.
- The week containing the first Thursday is also ISO Week 1.
- An ISO year can contain 52 or 53 weeks.
- The ISO week year can differ from the ordinary calendar year.
- January 1 can belong to the previous ISO year.
- Late December dates can belong to the next ISO year.
- Leap years can affect whether an ISO year contains 53 weeks.
- ISO week numbers should be stored together with the ISO week year when used as identifiers.
- ISO week numbers are for week grouping and should not be confused with elapsed-time calculations.
What is an ISO week number?
An ISO week number identifies a week according to the ISO 8601 week-date system. ISO weeks run from Monday through Sunday and are numbered from 1 to 52, with some ISO years containing Week 53.
When does ISO Week 1 start?
ISO Week 1 is the Monday-to-Sunday week that contains January 4, or equivalently, the week containing the year's first Thursday.
Does an ISO week always start on Monday?
Yes. Under the ISO week-date system, Monday is weekday 1 and Sunday is weekday 7.
Can January 1 belong to the previous ISO year?
Yes. If January 1 falls in the final ISO week of the previous week-based year, its ISO year can be one less than its calendar year.
Can December 31 belong to the next ISO year?
Yes. Some dates at the end of December can belong to Week 1 of the following ISO week-based year.
How many weeks are in an ISO year?
An ISO year contains either 52 or 53 complete weeks. A 53-week ISO year occurs only for certain calendar configurations.
Why does an ISO year sometimes have 53 weeks?
The 53rd week is required in calendar configurations where the ISO Week 1 and Monday-to-Sunday rules result in 53 complete ISO weeks within the week-based year.
Is ISO Week 1 the same as the week containing January 1?
No. ISO Week 1 is the week containing January 4 or the first Thursday. Therefore, the week containing January 1 can belong to either the current or previous ISO year.