current_datetime

Retrieves the current time as an object using the site's timezone.

Since
3.5.7 Added as this function is not present before WordPress 5.3.0
Returns
DateTimeImmutable

Date and time object.