Skip to content Skip to main navigation Skip to footer

How to count days in Excel?

How to count days in Excel?

When we work with Microsoft Excel, suddenly we need something that we do not know just a few seconds earlier. Surprisingly, whatever you need there is a solution in Microsoft Excel. If you need to count days there is a fantastic solution for it also. In this feature, we will discuss counting days, weeks, and months using Excel functions.

How to count days in Excel?

This function returns the number of days between two dates.

SYNTAX
=DAYS(end_date, start_date)

Following are the arguments of the DAYS function

  • end_date (required)– Up to which date you want to know the number of days.
  • start_date (required)– From the date, you want to know the number of days.

Remember that Microsoft Excel starts counting dates from January 1, 1900, and the value is stored. Any dates before January 1, 1900, will not be calculated by this formula.

Read More: Average formula in excel – AVERAGE function

Conditions

  • if both date arguments are numbers, the function usages (EndDate–StartDate) to calculate the difference.
  • If any one of the date arguments is text, that argument is treated as DATEVALUE(date_text) and returns an integer date instead of a time component.
  • if date arguments are numeric values that fall outside the range of valid dates, the function returns the #NUM! error value.
  • If date arguments are strings that cannot be parsed as valid dates, the function returns the #VALUE! error value.
  • If the start date is greater than the end date then the function returns with a negative value.

Count days in Excel using the DAYS function

Let’s calculate the days of the following dates.

How to count days in excel_01

Solutions with DAYS function

How to count days in excel_02

An alternative way to count days

You can count the days by deduction of two dates

How to count days in excel_03

Count days in Excel using the DATEDIF function

You can count days between two dates in another way using the DATEDIF function. This function is specially designed for calculating the difference between days, weeks, and years.

SYNTAX
=DATEDIF(start_date, end_date, “d”)

Following are the arguments of the DAYS function

  • start_date (required)– From the date, you want to know the number of days.
  • end_date (required)– Up to which date you want to know the number of days.
  • “d” returns the number of full days between the two dates.

Day Count in Excel using the DATEDIF function

How to count days in excel_04

Week Count in Excel using the DATEDIF function

How to count days in excel_05

Note that this result also needs to be formatted. Press CTRL + 1, then click Number Decimal places: 2.

Month Count in Excel using the DATEDIF function

SYNTAX
=DATEDIF(start_date, end_date, “m”)

The following are the arguments:

  • start_date (required)– From the date, you want to know the number of days.
  • end_date (required)– Up to which date you want to know the number of days.
  • the “m” returns the number of full months between the two days.

How to count days in excel_06

Year Count in Excel using the DATEDIF function

SYNTAX
=DATEDIF(start_date, end_date, “y”)

The following are the arguments:

  • start_date (required)– From the date, you want to know the number of days.
  • end_date (required)– Up to which date you want to know the number of days.
  • The “y” returns the number of full years between the two days.

How to count days in excel_07

How to calculate working days between two dates in Excel

SYNTAX
=NETWORKDAYS(start_date, end_date, [holidays])

The following are the arguments:

  • start_date (required)– From the date, you want to know the number of days.
  • end_date (required)– Up to which date you want to know the number of days.
  • holidays (Optional)–  Allows excluding a custom list of holidays from the day count.

How to count days in excel_08

If you want to deduct a custom holiday then you can add a custom holiday list.

How to count days in excel_09

How to calculate the number of days between today and another date

This is a little bit tricky. You can do it in two ways. One method I already discussed before type today’s date as end_date then use the DAYS function.

Another method, you can use the TODAY function, instead of end_dates.

How to count days in excel_11

How to count days in Excel? I hope you have received your answer. If you have any more queries please let us know. We will reply to your comment.

0 Comments

There are no comments yet

Leave a comment

Your email address will not be published. Required fields are marked *