State of Drupal 7: Lasting over a decade

Published On2020-12-26

State of Drupal 7

Drupal 7 was released back in 2011 January, and it's a major new version from the previous Drupal 6, that was widely adopted as well. Drupal 7 is still a maintained version, and it will receive official support until end of 2022. This makes Drupal 7 the longest supported Drupal version and one of the longest supported PHP projects ever, spanning over 11 years of security support.

At the time of its first release on 2011 January 05, it required PHP 5.2 as the minimum version. This meant that Drupal 7 could not require Composer for its dependency management, and to this date, Drupal 7 uses its own autoloader, and maintains rigorous coding standards to maintain compatibility older PHP versions.

This includes lack of namespaces, lack of short-array syntax, and relying on test and tooling that no longer receive updates. Anyone enjoying modern PHP code will find it quite cumbersome to maintain and fix Drupal 7 given how old the code base is, and massive use base it continue to maintain even after 9 years into its lifetime.

Drupal 7 still receives security updates, and occasional bug fixes by its current and most active maintainer Drew Webber (mcdruid) and the community.

Drupal 7 Market Share

Despite Drupal 8 being released on 2015 November 19, and Drupal 9 this year, Drupal 7 still has over 60% market share (source: drupal.org usage statistics).

Drupal 7 market share
Drupal 8 and Drupal 9 versions are slowly replacing old Drupal 7 web sites and adding brand new ones, but even after 9 years, Drupal 7 still holds more than 60% market share.

Drupal 7 market share
Drupal 8 is a major step forward in terms code quality and complexity, and due to massive changes in internal data structures and adoption of Symfony components, Composer, Twig, configuration management system, etc., a Drupal 7 to Drupal 8 is more of a migration rather than an upgrade.

Several contributed modules simply do not exist for Drupal 8, or are dramatically different in its functionality. Due to the differences in the template system, most Drupal 6 and 7 themes are not directly portable to Drupal 8 either.

Drupal 7 End-Of-Life

Drupal 7 will receive official support until 2022 November 28. This was previously set to 2021, but extended until 2022 due to the Covid-19 pandemic.

Similar to Drupal 6 LTS project, Drupal 7 will likely receive free and commercial support for security fixes (along with official Drupal security releases), and less often bug fixes after this date.

Drupal 7 will no longer receive official security updates after 2022 November 28.

State of PHP 8 Support in Drupal 7

PHP 8.0 is released with major new features and several backwards-incompatible changes.

Latest Drupal 7 version, Drupal 7.77, is not compatible with PHP 8.0.

Issue #3145797 tracks the progress of Drupal 7's PHP 8 support.

As of now, the major blocker is due to PHP 8.0 strictly enforcing LSP, and causing fatal errors in case it encounters mismatching method signatures. This is being discussed at issue #3185918. This is due to DatabaseConnection::query method not being compatible with the parent \PDO class, and because this method used frequently in Drupal, its fix might require coordination with other contributed modules.

In contributed modules, Views module requires a small deprecation notice fix (#3189937) related to PHP 8.0's deprecation notice if it encounters an optional parameter before the last required parameter.

All of the major issues Drupal 7 has with PHP 8 are already in the issue tracker, and it is likely that a new Drupal 7 version with support for PHP 8 will be released in coming weeks. Drupal 7 took its sweet time to commit compatibility fixes for PHP 7.4, so it might be a while until this new version.

Install PHP 8.0 on Debian/Ubuntu, including running multiple PHP versions side-by-side.

Recent Articles on PHP.Watch

All ArticlesFeed
What's New in WordPress 5.7

What's New in WordPress 5.7

WordPress 5.7 is just around the corner, and here is a summary of what's new and improved in WordPress 5.7.
Character escape sequences and numeric notations in PHP

Character escape sequences and numeric notations in PHP

A complete guide to character escape sequences and numeric notations (such as binary, octal, hexadecimal and decimal)
Best Markdown libraries for PHP

Best Markdown libraries for PHP

A comparison of features and performance of Markdown processing libraries for PHP.
Subscribe to PHP.Watch newsletter for monthly updates

You will receive an email on last Saturday of every month and on major PHP releases with new articles related to PHP, upcoming changes, new features and what's changing in the language. No marketing emails, no selling of your contacts, no click-tracking, and one-click instant unsubscribe from any email you receive.