PHP 8.1 or higher is required for Drupal 10. PHP versions 8.1. 0 through 8.1. 5 have a bug in the PHP OPcache that may cause intermittent fatal errors at runtime for class autoloading, so PHP 8.1 is recommended.