Good news! PHP 7.1 is being actively supported through 03 Apr 2025. After that point, it's advisable to upgrade to the latest version, since the PHP team will only offer security-related support until 03 Apr 2025, at which point PHP 7.1 will be considered "end-of-life".
php -v
PHP 7.1.x (cli) (built: ...)
<?php phpinfo(); ?>