
- Excel for mac, calculate the number of months between two dates how to#
- Excel for mac, calculate the number of months between two dates plus#
Unfortunately, there is not a similar function to calculate months in Excel. This is a handy function for figuring out something like age when you have a birthdate. I'll plug in the dates we already have in columns B and C so you can see how it works. YEARFRAC returns the number of years between dates, including fractional years. The YEARFRAC function takes three arguments: start date, end date, and an optional parameter called "basis" that we'll ignore for now. To calculate years between dates, we can use a function called YEARFRAC. This will give you some data to compare with the results of DATEDIF. To explain how DATEDIF works, the table below is set up to show all options available for Unit.įirst, however, let's calculate both years and months in a different way. Unit specifies whether you want the difference between dates in days, months, or years, with several variations. For reasons that are unknown, it's only documented in Excel 2000, but you can use it in your formulas in all Excel versions since that time.ĭATEDIF takes three arguments: start date, end date, and unit. The DATEDIF function is a "compatibility" function that comes from Lotus 1-2-3.
Excel for mac, calculate the number of months between two dates how to#
Select the option that suits you best in the Age drop-down list.In this video we'll look at how to calculate the number of years or months between dates using a function called DATEDIF and a function called YEARFRAC. You can convert a person's age to days, weeks, months, years, or get an exact number in years + months + days. You can enter the second date in your system format, find it in the calendar using the Expand arrow icon, or pick one in your Excel worksheet using the Select range icon. This option lets you get Excel formula to calculate age between two dates: the date of birth and any date you specify in the field. In other words, it will show how young the person is by comparing their birthday to the present day. This option will calculate the most current age from the date of birth.


To get the difference in months without years, tick off Exclude years and you will get "2 months". If you pick "Y+M" for the result, you will see "2 years 2 months".

If you choose to show the difference in months, you will get "26 months". Say, you are trying to compare "" and "". To see the difference in days and skip the month count, tick off the Exclude months box. If you want to omit years in your calculations and show the difference in months and days only, choose to Exclude years.
Excel for mac, calculate the number of months between two dates plus#
Also, you can choose to get your result in days plus time units (hours, minutes, seconds): "D + h + m" and "D + h + m + s".Įach option in the list shows a preview of the resulting value: You can find every possible option from a simple count of days, months, weeks, and years to unit combinations, like "Y + M + D". Open the Difference in drop-down list and decide on the way you'd like to see the result. Choose units to find the difference in.Use the =NOW or =TODAY functions in one of the fields and get a formula that will keep comparing a date to the current one.
