Jordi Boggiano has published the PHP version stats for the first part of 2017 on his site and PHP 7.1 has made the largest jump since he last published last year.
It is worth noting that the stats are taken from the Packagist project, so these are a subset of the entire community, and only from those projects that are utilizing Composer.
Here is a breakdown comparing the versions from now versus last year:
|PHP 5.6.30||14.73%||PHP 7.0||36.12% (+1.11)|
|PHP 7.0.15||9.53%||PHP 5.6||31.44% (-6.02)|
|PHP 5.5.9||6.12%||PHP 7.1||17.64% (+16.28)|
|PHP 7.0.17||6.00%||PHP 5.5||10.61% (-8.32)|
|PHP 7.1.3||5.88%||PHP 5.4||3.11% (-2.29)|
|PHP 7.1.4||3.65%||PHP 5.3||0.98% (-0.62)|
Jordi also includes the following in reference to the rise in 7.1 installs:
A few observations: With a big boost of PHP 7.1 installs, PHP 7 overall now represents over 50%. 5.3/5.4 are really tiny and even 5.5 is dropping significantly which is good as it is not maintained anymore since last summer. That’s a total of 85% of installs done on supported versions, which is pretty good.
And continues on with HHVM and if you should continue supporting it:
And because a few people have asked me this recently, while HHVM usage is not included above in the graph it is at 0.36% which is a third of PHP 5.3 usage and really hardly significant. I personally think it’s fine to support it still in libraries if it just works, or if the fixes involved are minor. If not then it’s probably not worth the time investment.
Finally, he shows a breakdown of what packages are currently requiring:
This is, as usual, moving pretty slowly. I think I can give up trying to advise for change, it doesn’t seem to be working.. On the other hand it looks like Symfony is going to use 7.0 or 7.1 for it’s v4 to come out later this year, so hopefully that will shake things up a bit and make more libraries also realize they can bump to PHP 7.
Laravel 5.5 is also moving to PHP 7.0+ so any packages that are designed for it will have to bump their requirements as well. With both Laravel and Symfony moving I imagine this will indeed cause the minimum versions to change when he generates these next year.
See Jordi’s post for more details and for more stats.
Join the weekly newsletter and never miss out on new tips, tutorials, and more.
Bugsnag T-Shirt Offer – Sponsor
Get instant alerts and detailed diagnostics for your Laravel errors. For a limited time, get a free t-shirt when you…
Laravel Valet Supports Custom Per-Site Drivers
In Laravel Valet you can create your own local driver that applies to a single project. Name it LocalValetDriver.php…