WEEKNUM Function in Apple Numbers: Syntax, Examples and Troubleshooting
Calculate Sunday- or Monday-start calendar week numbers in Numbers, including year-end and ISO traps with examples.
Verification status: Official documentation referenced; example outcomes independently reasoned or arithmetically checked where stated. Not executed in Apple Numbers. How formula examples are checked
Quick answer
=WEEKNUM(DATE(2024,1,7),1) is expected to return 2, while =WEEKNUM(DATE(2024,1,7),2) is expected to return 1. The same Sunday falls in different week-number buckets depending on whether the week starts Sunday (1, Apple’s default) or Monday (2). Use an explicit mode in shared business reports.
Purpose and when to use it
WEEKNUM maps a date to a numbered week within a calendar year under a Sunday-first or Monday-first convention. Use it for weekly operational reports, recurring booking summaries and year-end rollover audits. It is not an ISO-8601 week-number function; Apple’s separate ISOWEEKNUM(date) documents ISO numbering, where a late-December date may be ISO week 1 of the next ISO year.
Exact Apple syntax and documented modes
=WEEKNUM(date, first-day)
| Position | Input | Required? | Documented meaning |
|---|---|---|---|
| 1 | date |
Yes | Date/time value or date string. |
| 2 | first-day |
No | Modal value, 1 (or omitted) for Sunday-first, 2 for Monday-first. |
The official Apple WEEKNUM page documents exactly modes 1 and 2. These are not interchangeable with WEEKDAY(...,3) or Excel’s additional modes. The source does not describe an optional third argument or a 21 ISO mode; use Apple’s ISOWEEKNUM for ISO reporting.
Reproducible week-number comparison table
Create one Numbers table named CalendarAudit. Make row 1 a header and fill columns A:C with the year, month and day integers below. Enter =DATE(A2,B2,C2) into D2, fill D2 down through D9, and format D as Date & Time. Dates are shown here as ISO-style labels only to eliminate regional display ambiguity. Do not type the dates in column D as text. All results in E:J are expected results independently calculated from calendar arithmetic, not observations from running Numbers.
| Row | A Year | B Month | C Day | D Date formula result* | E Sun=1 | F Mon=1 | G Mon=0 | H Week Sun | I Week Mon | J ISO week |
|---|---|---|---|---|---|---|---|---|---|---|
| 2 | 2024 | 1 | 1 | 2024-01-01 | 2 | 1 | 0 | 1 | 1 | 1 |
| 3 | 2024 | 1 | 7 | 2024-01-07 | 1 | 7 | 6 | 2 | 1 | 1 |
| 4 | 2024 | 1 | 8 | 2024-01-08 | 2 | 1 | 0 | 2 | 2 | 2 |
| 5 | 2024 | 1 | 14 | 2024-01-14 | 1 | 7 | 6 | 3 | 2 | 2 |
| 6 | 2024 | 2 | 29 | 2024-02-29 | 5 | 4 | 3 | 9 | 9 | 9 |
| 7 | 2024 | 12 | 31 | 2024-12-31 | 3 | 2 | 1 | 53 | 53 | 1 |
| 8 | 2025 | 1 | 1 | 2025-01-01 | 4 | 3 | 2 | 1 | 1 | 1 |
| 9 | 2026 | 10 | 11 | 2026-10-11 | 1 | 7 | 6 | 42 | 41 | 41 |
*D is computed by Numbers; its visible formatting depends on the document locale. The J column is included for conceptual ISO comparison and should use =ISOWEEKNUM(D2) if you choose to create it; Apple’s official ISO page was inspected separately.
In H2 enter =WEEKNUM(D2,1) and fill to H9. In I2 enter =WEEKNUM(D2,2) and fill to I9. For independent comparison, E:G use the WEEKDAY conventions documented in the companion official function, and J uses =ISOWEEKNUM(D2). All row values above are expected outcomes independently calculated from the stated week-boundary rules, not results captured in Numbers.
For a direct confirmation from Apple’s own documentation, =WEEKNUM("7/12/2009",1) is shown as 29 and mode 2 as 28 (its English example refers to July 12, 2009). Avoid that ambiguous-looking short date string in imported regional data; DATE(2009,7,12) identifies the same intended date without locale parsing uncertainty.
Year-end rollover: a trap for weekly dashboards
Take December 31, 2024 (row 7): independently calculated WEEKNUM(…,1) = 53 and WEEKNUM(…,2) = 53, while ISOWEEKNUM(…) = 1 because ISO rules place this date in the first ISO week of 2025. Therefore do not join weekly figures by the numeric week alone, and do not simply concatenate YEAR(date) with an ISO week number without determining the corresponding ISO week-year. The fixture shows why calendar year versus ISO week-year matters.
For one consistent non-ISO grouping, retain calendar year, week-number mode and week number as separate fields. This avoids merging Week 1 of multiple years and makes a switch from Sunday-first to Monday-first visible. For ISO data, record the official ISO week number and independently validate week-year alignment.
Advanced practical uses
Weekly order grouping: Suppose each row in CalendarAudit represents an order date in D. Put =WEEKNUM(D2,2) in a calculated column to group orders by Monday-start week, and put =YEAR(D2) in another. If you group only by numeric week 1, entries from different calendar years will collide.
Sunday boundary check: The fixture has Sunday January 7 in row 3 and Monday January 8 in row 4. Under mode 1, both are expected in week 2; under mode 2, January 7 is in week 1 and January 8 is in week 2. This directly tests the meaning of the optional argument.
ISO audit column: With a test date in D7 (December 31, 2024), compare =WEEKNUM(D7,2) (expected 53) against =ISOWEEKNUM(D7) (expected 1, independently calculated with ISO-8601 week logic). Never describe WEEKNUM(...,2) as ISO-compliant merely because it starts on Monday.
Errors, limits and troubleshooting
- Off-by-one weekly totals: Check
first-day. Omitting it means Sunday-first mode1; using2shifts boundaries to Mondays. - January versus December anomaly: A year’s last days may be ISO week 1 of the next ISO year;
WEEKNUMandISOWEEKNUMare deliberately different methods. - Unexpected zero, huge number or formula error: Check that D is a date value, not text, and that the formula is pointing at the intended table cell. Rebuild D with
=DATE(A2,B2,C2)when uncertain. first-day=3isn’t supported here: Apple documents3forWEEKDAYbut only1and2forWEEKNUM. Don’t copy modes between two functions with similar parameter names.- Custom or retail week systems: Neither documented mode proves support for 4-4-5 fiscal calendars, Monday weeks with a custom year start, or ISO standards. Those need a separate algorithm and validation.
- Datetime time zone and region: Use actual date cells; typed date strings can be ambiguous in different locales. The official page doesn’t guarantee a particular error message for malformed inputs; native execution has not been verified.
Formula entry, table references, language, and supported versions
In an English-language Numbers document, begin with = and use the comma-separated arguments shown in Apple’s Functions Help. If your device is configured to use a comma as the decimal separator, Apple’s instructions say to separate formula arguments using semicolons. Example: =WEEKDAY(D2;2) rather than =WEEKDAY(D2,2) in such a locale. Quotation marks around a date string do not remove local date-parsing ambiguity; construct examples from numeric DATE(year,month,day) inputs or genuine date-formatted cells instead.
Numbers is table-centred. When the formula is in the same table, D2 identifies that table’s cell; when referring to a different table, select the actual source cell in the formula editor so Numbers inserts the correct table-qualified reference. Do not silently assume Excel’s Sheet1!D2 syntax applies. The expected outputs below use an English Functions Help 15.4 reference path consulted 2026-10-11, not a claim that these functions first appeared in app release 15.4. Apple describes date/time functions in shared Formulas and Functions Help; this research did not establish a minimum Numbers version on macOS, iOS, iPadOS or iCloud. Native verification on each intended app/platform/version is pending.
Testing note: This guide uses documentation-derived examples, not results observed in Apple Numbers.
Official reference and verification
Verification status: Official documentation checked; example outcomes were independently reasoned or arithmetically checked where applicable. Not executed in Apple Numbers.
- No genuine Apple Numbers screenshots are included; this guide does not use mock application images.