Excel YEAR Function

 Summary

The Excel YEAR function returns the year component of a date as a 4-digit number. You can use the YEAR function to extract a year number from a date into a cell or to extract and feed a year value into another formula like the DATE function.

Purpose

Get the year from a date

Return value

Year as 4-digit number

Syntax

=YEAR (date)

The result will be


Arguments

date - A valid Excel date.

Usage notes

The YEAR function extracts the year from a given date as a 4-digit number. For example:

=YEAR("23-Aug-2021") // returns 2021

=YEAR("11-May-2019") // returns 2019

You can use the YEAR function to extract a month number from a date into a cell or to feed a month number into another function like the DATE function:

=DATE(YEAR(A1),1,1) // first of same year



The result will be


Notes

• Date must be a valid Excel date.

• YEAR will return a #VALUE error on text values

 Recommended Articles

Units of Measures

If Function

Comments

Popular posts from this blog

TDS on Salary – Entry in Tally

Post Dated Cheque (PDC) Management

Personal Accounts in Tally