Javascript Get Current Year
JavaScript get the current year in different formats. For example, you may want to display the current year as 2024 or 24 . In this tutorial, we will learn how to get the current year in JavaScript using different methods and formats. We will use the JavaScript Date object and its methods to get the current year in various ways.
written
reviewed
updated
Thanks for your feedback!
Your contributions will help us to improve service.
How to Get Current Year in Javascript?
This below example shows how to use the Date object and the getFullYear() method to get the current date using JavaScript
Output of Js Get Current Year
Get Current Year in 2 Digit Format
Copied to Clipboard
Ad