### Number of Days Between Dates in Excel & Google Sheets

##### Associated Files Download Links

In this Article

*This tutorial will teach you how to calculate the number of days between two dates in Excel and Google Sheets.*

## Excel Subtract Dates

In Excel, dates are stored as serial numbers:

This allows you to subtract dates from one another to calculate the number of days between them:

1 |
=C3-B3 |

If the end_date is before the start_date you’ll receive a negative answer:

If you need the absolute number of days between the dates, use the ABS Function to return the absolute value:

1 |
=ABS(C3-B3) |

### Subtracting Dates with Times

In Excel, times are stored as decimal values. A decimal value attached to a serial number represents a Date & Time:

If you subtract a Date and Time from another Date and Time. You’ll receive a Date and Time answer (number of days, hours, minutes, seconds between the two dates):

Notice how the number of days between the dates is *3*, but the decimal value is *2.2* because of the time difference? This may or may not be what you want.

Of course, you could use the TRUNC Function to find the difference between the dates:

1 |
=TRUNC(C3)-TRUNC(B3) |

But you can also use the DAYS or DATEDIF functions for an easier calculation…

## DAYS Function – Calculate Difference Between Dates

The DAYS Function calculates the number of days between dates, ignoring times.

1 |
=DAYS(C3,B3) |

The DAYS Function will return negative values, so you may want to use the ABS Function for the absolute number of days between dates:

1 |
=ABS(DAYS(C3,B3)) |

### DAYS360 Function

The DAYS360 Function works the same as the DAYS Function, except it assumes a 360-day year where each month has 30 days. Notice the difference in calculations:

1 |
=DAYS360(B3,C3) |

## DATEDIF Function – Number of Days Between Dates

The DATEDIF Function can be used to calculate the date difference in various units of measurement, including days, weeks, months, and years.

To use the DATEDIF Function to calculate the number of days between dates set the unit of measurement to “d” for days:

1 |
=DATEDIF(B3,C3,"d") |

Unlike the other methods, the DATEDIF Function will not work if the end_date is before the start_date, instead it will throw a #NUM! error.

To calculate difference between dates with other units of measurement use this table:

## Calculate Number of Days Between Today and Another Date

To calculate the number of days from Today to another date, use the same logic with the TODAY Function for one of the dates.

This will calculate the number of days **since a date**:

1 |
=DAYS(TODAY(),B3) |

This will calculate the number of days **until a date**:

1 |
=DAYS(B3,TODAY()) |

## Calculate Working (Business) Days Between Dates

The NETWORKDAYS Function allows you to calculate the number of working (business) days between two dates:

1 |
=NETWORKDAYS(B4,C4) |

By default, NETWORKDAYS will ignore all holidays. However you can use a 3rd optional argument to define a range of holidays:

1 |
=NETWORKDAYS(B4,C4,F3:F4) |

## Google Sheets – Days Between Dates

All of the above examples work exactly the same in Google Sheets as in Excel.