Google Sheets WEEKNUM Function: Syntax & Examples

How-to basics · Updated November 23, 2026

The Google Sheets WEEKNUM function returns the week number of a given date within the year, using the syntax WEEKNUM(date, [type]). For example, =WEEKNUM(DATE(2025,1,6)) returns 2, because January 6, 2025 falls in the second week of the year. The optional type argument controls which day the week starts on, giving you flexibility for different calendar conventions.

What Is WEEKNUM Used For?

WEEKNUM is a date function that helps you group, compare, or label dates by their position in a calendar year. Common uses include:

  • Tracking weekly sales or project milestones
  • Creating weekly reports or dashboards
  • Calculating the number of weeks between two dates
  • Sorting or filtering data by week number

It is part of Google Sheets’ Date category, alongside functions like TODAY, DATE, and WEEKDAY. Unlike Excel, which has multiple week-numbering systems (WEEKNUM, ISOWEEKNUM), Google Sheets only has WEEKNUM, but its type parameter covers most common conventions.

Syntax and Arguments Explained

The function takes two arguments:

  • date (required): The date you want to evaluate. This can be a cell reference containing a date, a date returned by another function like DATE(), or a text string like “1/6/2025” that Google Sheets recognizes as a date.
  • type (optional): A number that determines which day the week starts on. The default is 1, meaning Sunday. The available values are:
  1. 1 – Week starts on Sunday (default)
  2. 2 – Week starts on Monday
  3. 11 – Week starts on Monday (ISO 8601)
  4. 12 – Week starts on Tuesday
  5. 13 – Week starts on Wednesday
  6. 14 – Week starts on Thursday
  7. 15 – Week starts on Friday
  8. 16 – Week starts on Saturday

Note: Types 11-17 are ISO-based, meaning they follow the ISO 8601 standard where week 1 is the week containing the first Thursday of the year. Types 1-7 are the traditional US-style numbering where week 1 is the week containing January 1.

How to Use WEEKNUM: Step-by-Step Examples

To see WEEKNUM in action, try these examples in a blank Google Sheet:

  1. In cell A1, enter a date, e.g., 3/15/2025.
  2. In cell B1, enter the formula =WEEKNUM(A1). This returns 12, because March 15, 2025 is the 12th Sunday-start week of the year.
  3. In cell B2, enter =WEEKNUM(A1, 2). This returns 11, because with Monday-start weeks, the same date falls in week 11.

You can also use a date directly: =WEEKNUM(DATE(2025,12,31)) returns 1 (since December 31, 2025 falls in week 1 of 2026 under the default system, which is a quirk of the US convention).

Choosing the Right Type Argument

The type argument is crucial for accurate results. Here’s how to decide:

  • US business or academic calendars often start the week on Sunday – use type 1.
  • International business or ISO standards start on Monday – use type 2 or 11.
  • Custom workweeks (e.g., a team that starts on Thursday) – use types 12-16.

For ISO 8601 compliance (used widely in Europe and for week numbers in many software systems), type 11 is the safest choice because it ensures week 1 is the week with the first Thursday. Type 2 also starts on Monday but uses the simpler rule that week 1 contains January 1, which can produce a week 1 that is only one day long.

Common Problems and How to Fix Them

Here are frequent issues users encounter:

  • #VALUE! error: This occurs if the date argument is not a valid date. For example, =WEEKNUM("hello") returns an error. Ensure the date is a real date or a text string that Sheets can parse.
  • Wrong week number at year boundaries: The default type 1 can return 1 for dates in late December that belong to the next year’s first week. If you need consistent ISO weeks, use type 11.
  • Text dates not recognized: If you type a date as text like “2025-01-06”, Sheets usually parses it, but if it doesn’t, wrap it in DATEVALUE() or use DATE().

WEEKNUM vs. ISOWEEKNUM and Other Functions

Google Sheets does not have a separate ISOWEEKNUM function (unlike Excel). Instead, you use WEEKNUM(date, 11) for ISO weeks. If you need the day of the week, use WEEKDAY(date, [type]). For example, =WEEKDAY("1/6/2025", 2) returns 1, meaning Monday (where Monday=1).

To calculate the number of weeks between two dates, you can subtract the WEEKNUM values, but be careful at year boundaries. A more robust approach is to use =INT((B1-A1)/7) where A1 and B1 are dates, but that counts 7-day intervals, not calendar weeks.

Practical Use Cases and Tips

Here are some real-world scenarios where WEEKNUM shines:

  • Weekly sales aggregation: Use =WEEKNUM(A2, 2) in a helper column, then use a pivot table to sum sales per week.
  • Project timeline: Label tasks with week numbers to see which week a milestone falls in.
  • Attendance tracking: Count how many weeks an employee was present by filtering on week numbers.

Tip: Always use a consistent type across your entire sheet to avoid confusion. If you share the sheet with international collaborators, consider using type 11 to align with ISO standards.

Frequently Asked Questions

Does Google Sheets have an ISOWEEKNUM function?

No, Google Sheets does not have a separate ISOWEEKNUM function. To get ISO week numbers, use WEEKNUM(date, 11). This follows the ISO 8601 standard where weeks start on Monday and week 1 contains the first Thursday of the year.

Why does WEEKNUM return 1 for December 31, 2025?

With the default type 1 (Sunday start), the week containing January 1 is considered week 1. December 31, 2025 falls on a Wednesday, and the Sunday of that week is December 28, 2025, which is in 2025. However, because the week that starts on December 28 includes January 1, 2026, that entire week is counted as week 1 of 2026. So WEEKNUM returns 1 for December 31, 2025. To avoid this, use type 11 for ISO weeks.

Can I use WEEKNUM with a date stored as text?

Yes, if the text is a recognized date format (e.g., “1/6/2025” or “2025-01-06”), WEEKNUM will parse it automatically. If not, you can use DATEVALUE() to convert it first, like =WEEKNUM(DATEVALUE("January 6, 2025")).

What is the difference between type 2 and type 11?

Both start the week on Monday, but they differ in how week 1 is defined. Type 2 uses the rule that week 1 is the week containing January 1. Type 11 uses the ISO rule that week 1 is the week containing the first Thursday of the year. This means type 11 can sometimes have a week 1 that starts in the previous year, while type 2 always has January 1 in week 1.

How do I get the week number for a date in a different year?

WEEKNUM only returns the week number within the year of the given date. If you need a continuous week count across years, you can calculate it with a formula like =YEAR(A1)*100 + WEEKNUM(A1, 2) to create a week identifier like 202512, but this is not a standard function.

Related

Try it: the Date Difference Calculator: days, months, years and weekdays between two dates, with the DATEDIF formulas.

More in How-to basics

Sources: Function behaviour and menu paths: Microsoft Support documentation for Excel. Method & sources

Spotted an error in this guide? Let us know.