The WEEKNUM function returns an integer representing the week number, from 1 to 53, of the year for the supplied date. 

Syntax

=WEEKNUM(serial_number,[return_type])

Arguments

Argument Description
serial_number The Excel date, that you want to return the week number for.
[return_type] An optional argument that specifies which weekday should be treated as the start of the week. The default is 1. The possible values of [return_type] are:

[return_type] Meaning
1 Week runs from Sunday to Saturday.
2 Week runs from Monday to Sunday
11 Week runs from Monday to Sunday
12 Week runs from Tuesday to Monday
13 Week runs from Wednesday to Tuesday
14 Week runs from Thursday to Wednesday
15 Week runs from Friday to Thursday
16 Week runs from Saturday to Friday
17 Week runs from Sunday to Monday

Note: The serial_number argument for the WEEKNUM function should be input as either:

  • A reference to a cell containing a date or,
  • A date returned from another function or formula

Examples

  A B C
1 Data    
2 Sun 10-Aug-2014    
3      
4 Formula Result Notes
5 =WEEKNUM(A2) 33 Number of the week in the year that 8/10/2014 occurs, based on weeks beginning on Sunday (default)
6 =WEEKNUM(A2,2) 32 Number of the week in the year that 8/10/2014 occurs, based on weeks beginning on Monday

Usage note: One use for the Excel WEEKNUM function is if you have a large number of events and you want to analyse the peak weeks throughout the year.

Common Function Error(s)

Problem What went wrong
#VALUE! Occurs if the supplied serial_number cannot be recognized as a numeric value or a date
#NUM! Occurs if the supplied serial_number argument is numeric but is out of range for the current date base, or the supplied [return_type] argument is not one of the above listed permitted values