Article

ZF1 Migration Planning: Strangler Paths that Work

Plan ZF1 retirement with inventory, containment, strangler routes, and successor choices—without abusing laminas-migration.

Successful ZF1 exits are project-managed: inventory, risk containment, incremental replacement, and proof via tests. They are not a single Composer plugin run. Official laminas-migration is for ZF2/ZF3-era stacks—plan ZF1 differently.

Recommended phases

  1. Inventory — routes, jobs, integrations, auth, DB writers (structure).
  2. Contain — isolate runtime; document EOL PHP risk (PHP 8 brief).
  3. Stabilize — Composer for app code, prepared statements, password hashing.
  4. Strangle — move high-churn endpoints first behind a new front controller.
  5. Retire — delete ZF1 modules only after traffic and jobs are proven elsewhere.
LEGACY monolith:  / * → public/index.php (ZF1)
MODERN hybrid:    /api/v2/* → new app
                  /admin/*  → ZF1 (temporary)
                  /         → marketing site (static/new)

Successor options commonly include Laminas MVC (greenfield modules), another maintained framework, or purpose-built services. Cross-link from ZF to Laminas for teams also owning ZF2/ZF3 systems, and PHP 5 to modern PHP for runtime sequencing.

Related tools

Related reading