Jonatan Matajonmatum.com
conceptsnotesexperimentsessays
© 2026 Jonatan Mata. All rights reserved.v2.1.1
Concepts

Strangler Fig Pattern

Incremental migration strategy that gradually replaces a legacy system with new components, progressively routing traffic until the old system can be retired.

seed#strangler-fig#migration#legacy#pattern#modernization#architecture

What it is

The Strangler Fig pattern (named after the strangler fig tree) is a strategy for migrating legacy systems incrementally. Instead of a complete rewrite — the dreaded "big bang" that fails more often than it succeeds — new components are built that gradually replace functionality from the old system while it continues operating.

Martin Fowler described it in 2004, inspired by the strangler figs of Australia: seeds that germinate in the canopy of a host tree, grow roots downward, and eventually envelop and replace the original tree.

Why it matters

Complete rewrites are the graveyard of software projects. The Strangler Fig pattern offers a pragmatic alternative:

  • Controlled risk — each migration is small and reversible
  • Continuous value — the legacy system keeps working while the new one is built
  • Incremental learning — the team discovers hidden legacy requirements gradually, not at the end
  • Sustainable funding — continuous investment is justifiable because each iteration delivers value

Process

  1. Place a proxy/facade in front of the legacy system — this is the control point for routing traffic
  2. Implement new functionality in the new system for a specific route or feature
  3. Gradually route traffic to the new system (by percentage, user, or region)
  4. Validate and monitor — compare behavior between both systems
  5. Repeat until legacy receives no traffic
  6. Retire the legacy system when no longer needed

When to use it

  • Monolithic systems that need modernization but cannot stop
  • Database migrations where consistency is critical
  • On-premise to cloud transitions
  • Replacement of obsolete frameworks or languages

When not to use it

  • Small systems where a rewrite takes less than a sprint
  • When the legacy system has no clear interface to intercept
  • If there is no way to selectively route traffic

Variants

VariantMechanismWhen to use
Strangler Fig (classic)HTTP proxy gradually redirects trafficMigrating web monolith to microservices
Branch by AbstractionInternal code abstractionReplacing internal components without changing the API
Parallel RunRun both systems and compareWhen correctness is critical (payments, calculations)
Feature ToggleFeature flags control which users see the new systemGradual migration by user segment

References

  • Strangler Fig Application — Martin Fowler, 2004. The original article that named the pattern.
  • Legacy Application Strangulation — Paul Hammant, 2013. Real-world case studies of the pattern in practice.
  • Strangler Fig Pattern — Azure — Microsoft, 2024. Pattern implementation guide.

Related content

  • Microservices

    Architectural style structuring an application as a collection of small, independent, deployable services, each with its own business logic and data.

  • API Gateway Pattern

    Pattern providing a single entry point for multiple microservices, handling routing, authentication, rate limiting, and response aggregation.

  • Hexagonal Architecture

    Architectural pattern isolating business logic from the outside world through ports and adapters, facilitating testing and technology changes.

  • DevOps Practices

    Set of technical and cultural practices that implement DevOps principles — from Infrastructure as Code to blameless post-mortems. The "how" behind the philosophy.

Concepts