Day Number of the Year – Formula for Excel or Google Sheets

This tutorial will teach you how to calculate a date’s day number of the year or find the nth day of the year. Examples work for Excel and Google Sheets.

Day Number of year Main

Date’s Day Number of the Year

To calculate a date’s day number of the year you can calculate the difference between the date and the first day of the year:

Day Year to date

Notice we need to add 1 to the end of the formula to calculate the correct day number. Instead we can set the day to 0 in the Date Function:

Year to date Day0

nth Day of the Year

Conversely you can calculate the nth day of the year by adding n days to 12/31 of the previous year:

Nth Day of the Year

Notice we do this by once again setting day =0 in the Date Function.

Today’s Day Number

Use the TODAY Function to calculate today’s day number:

Today's Day Number

Google Sheets – Day Number Of The Year

All of the above examples work exactly the same in Google Sheets as in Excel.
Day-Number of year Google Sheet

Excel Practice Worksheet

Practice Excel functions and formulas with our 100% free practice worksheets!

  • Automatically Graded Exercises
  • Learn Excel, Inside Excel!