Symfony 4.0

4.0 released 30 November 2017, latest 4.0.15.

Symfony 4.0 reached end of life on 1 January 2019.

What changed

Symfony 4.0 is the next major line after Symfony 3.4 and removes APIs and behaviors that had been deprecated in the 3.x series. It raises the minimum PHP requirement to PHP 7.1.3. The recommended application model moved toward the Symfony Flex-based skeleton, with a simpler project layout, recipe-driven package configuration, environment variables for configuration, and convention-based service loading, autowiring, and autoconfiguration. Existing Symfony applications were not required to adopt the new skeleton immediately, but upgrades needed to account for removed deprecated code and for dependency constraints tied to older PHP versions.

What staying costs

Symfony 4.0 has reached end of life, so upstream no longer provides security fixes, bug fixes, or compatibility updates for this line. A discovered framework vulnerability or incompatibility must therefore be accepted, mitigated externally, or patched and maintained by the team. Its PHP baseline and older dependency ecosystem can also prevent upgrades to currently supported PHP versions, bundles, database drivers, and platform tooling. Staying on 4.0 increases the likelihood that Composer dependency resolution, CI images, deployment environments, and third-party integrations will require exceptions or locally maintained patches.

What to do

Start by inventorying the application’s PHP version, Symfony packages, bundles, custom framework integrations, and Composer constraints. Upgrade the application within the Symfony 4.x line to the latest 4.x release first, resolve Composer conflicts, and run the full test suite while treating deprecation notices as migration work rather than noise. Use static analysis and runtime testing to find calls to removed or deprecated framework APIs, especially custom event listeners, controllers, service definitions, security configuration, console commands, and bundle extensions. Then plan successive major-version upgrades to a currently supported Symfony line, updating PHP and third-party packages as required at each step. If the project still uses the older application structure, evaluate a controlled move to Flex conventions, but keep that refactoring separate from behavior-changing framework upgrades where possible.

We can tell you what moving off Symfony 4.0 involves.

What it takes to move off Symfony 4.0 depends on what you built on it — the version you are on, how much depends on it, and how much of the work is mechanical. Leave your email with this version and we can tell you what that looks like for you.

Not sure yet? Get my plan