To call the current year in any WordPress website you can do so by using the following.
Functions.php
Add the following code to your WordPress themes functions.php file.
function year_shortcode() {
$year = date(‘Y’);
return $year;
}
add_shortcode(‘year’, ‘year_shortcode’);
Usage
Then, add the following shortcode anywhere on your website to call the current year
[year]