Choosing a modernization path for legacy and mainframe systems: the 7 Rs with a decision table

In brief

How to choose between retire, retain, rehost, relocate, repurchase, replatform and refactor for legacy and mainframe systems, with an illustrative cost model.

Steve Elliott

Steve Elliott · · 6 min read


On this page
  1. What are the 7 Rs as AWS and Microsoft define them today?
  2. Which path fits which situation?
  3. What do the providers say about mainframes specifically?
  4. What does each path cost? An illustrative comparison
  5. When do "move first, modernize later" and the big-bang rewrite disappoint?
  6. What should a modernization plan contain?
  7. Sources

Choose the path by what has to change. If the business no longer needs an application, retire it; if it needs nothing new from it, retain it or move it unchanged; if it needs it to change faster than it can today, replace it with a package or refactor it in slices, and price the years of running old and new side by side before you decide.

For mainframe systems the same rule holds, with one addition: the label matters less than what actually moves. In our view, the two choices most likely to disappoint are moving code unchanged as a "first step" that never gets a second, and the big-bang rewrite.

What are the 7 Rs as AWS and Microsoft define them today?

As of November 2026, AWS Prescriptive Guidance lists seven strategies, which it calls the 7 Rs. Microsoft's Cloud Adoption Framework lists eight, last updated July 2025, and splits AWS's refactor into three.

AWS Prescriptive GuidanceWhat AWS meansMicrosoft CAF equivalent
RetireDecommission or archive; shut down the serversRetire
RetainKeep in the source environment, possibly for laterRetain
Rehost (lift and shift)Move to the cloud without changing the applicationRehost
RelocateMove many servers at once, unchanged, to a cloud version of what they run on nowNo separate strategy
Repurchase (drop and shop)Replace with a different version or product, such as SaaSReplace
Replatform (lift, tinker and shift)Move and add some optimization, such as a managed databaseReplatform
Refactor or re-architectChange the architecture to use cloud-native featuresRefactor, Rearchitect, Rebuild

In our view, Microsoft's split is useful. Its refactor "improves the internal structure of code without adding new features"; rearchitect redesigns the workload; rebuild is a full cloud-native redevelopment. We think their costs differ widely, yet one AWS label covers all three.

The providers differ on sequence. AWS doesn't recommend refactoring during large migrations; it suggests moving first and modernizing afterwards. Microsoft says rehost suits a workload only if it will stay in its current state for at least two years; if modernization is likely, it says to consider refactoring or rearchitecting instead. In our view both are reasonable: AWS's page is written for large migrations, Microsoft's for one workload.

Which path fits which situation?

The table is our synthesis. Triggers come from the AWS and Microsoft pages; the right-hand checks are our view of what gets missed. Feed it from an application rationalization exercise: TIME says which applications to act on, this table says how.

SituationLikely pathProvider triggersCheck before committing
No business value; little or no useRetireAWS: no inbound connection for 90 days; CPU and memory below 5%Who still needs the data, and for how long
Stable, compliant, no driver to moveRetainMicrosoft: stable, no near-term driver, low return from migratingA review date and the next end-of-life milestone
Data center exit date; application won't change for two yearsRehost or relocateMicrosoft's two-year test; AWS: large numbers of machines, fastWhether run cost actually falls, or only moves
Gains from managed services with little code changeReplatformAWS: managed database, OS upgrade, containers without code changesLicensing terms on the new runtime
Commodity function with a mature SaaS marketRepurchaseMicrosoft: CRM, HR and collaboration as common casesData migration, process change, retraining
Business demand the system can't meet; slow to change; poorly testedRefactor, in slicesAWS: monolith hindering delivery; nobody knows how to maintain itCode access, test coverage, a funded team for years
Obsolete, modernization not feasibleRebuildMicrosoft: legacy obsolete or modernization not feasibleLegacy run cost until cutover; whether it can be done in slices

Under retain, AWS lists mainframe, mid-range and non-x86 Unix applications as candidates in a large migration. Retain is a legitimate answer if it carries a date.

What do the providers say about mainframes specifically?

Both describe two broad routes: keep the code and change where it runs, or convert the code.

  • AWS. The AWS Mainframe Modernization user guide describes automated refactoring, powered by AWS Transform for mainframe, which converts the legacy stack into a Java application "while preserving functional equivalence." It describes replatforming on Rocket Software's (formerly Micro Focus) runtime, which keeps the application language, code and artifacts. But as of November 2026, AWS's undated availability page says both of the service's runtime experiences are closed to new customers, lists Replatform with Rocket among the affected capabilities, and points new projects to vendor-direct offerings and AWS Transform.
  • Microsoft. The Azure Architecture Center's general mainframe refactor architecture says refactoring can automatically convert code to Java or .NET and pre-relational databases to relational ones. It notes that emulated PL/I or COBOL typically runs on VMs while converted applications use containers. It describes two methods: convert everything in one process, which "carries some risk" because conversion, data migration and testing must line up, or migrate gradually.

So the labels differ. AWS files unchanged COBOL on Rocket's runtime under replatform; Microsoft's refactor architecture covers both emulation and conversion. In our view, a mainframe modernization business case should say, not label, whether the language, runtime, data store and hosting each change. Each moves cost, risk and skills.

What does each path cost? An illustrative comparison

All numbers are illustrative, from no company. Take one COBOL policy administration application with an annual run cost of $4.0 million, covering its share of mainframe capacity, software licenses and support staff. Assumptions: the legacy system runs at full cost until cutover, one-off costs fall within the migration period, and there is no discounting or inflation. Retire is not an option here because the business still needs the function.

Path ($M)One-off costMonths to cutoverRun cost a year after cutover5-year total10-year total
Retain0n/a4.020.040.0
Replatform onto an emulation runtime, code unchanged2.0122.214.825.8
Automated refactor to Java5.0241.417.224.2
Repurchase a SaaS package6.0242.020.030.0
Big-bang rewrite15.0361.029.034.0

Five-year total = one-off + legacy run until cutover + new run after. Emulation: 2.0 + 4.0 + (4 × 2.2) = 14.8. Refactor: 5.0 + 8.0 + (3 × 1.4) = 17.2. Repurchase: 6.0 + 8.0 + (3 × 2.0) = 20.0. Rewrite: 15.0 + 12.0 + (2 × 1.0) = 29.0.

Emulation wins over five years and refactor edges ahead over ten, so the horizon decides the answer. The rewrite never wins, mostly because three years of legacy run cost during the build add $12.0 million before it saves anything. And the savings assume run cost actually falls at cutover. If the application uses a share of a mainframe that stays for other workloads, it may not; the same question of what cost really leaves arises in cloud repatriation economics.

Now test risk. Suppose the rewrite and refactor each slip a year and the emulation move six months, with the team costing one-off cost divided by build years ($5.0M, $2.5M and $2.0M a year):

  • Rewrite: 29.0 + 4.0 legacy run + 5.0 team − 1.0 new run not yet incurred = $37.0M over five years.
  • Refactor: 17.2 + 4.0 + 2.5 − 1.4 = $22.3M.
  • Emulation: 14.8 + 2.0 + 1.0 − 1.1 = $16.7M.

The longer the path, the more a slip costs: every month of delay is a month of paying for two systems.

When do "move first, modernize later" and the big-bang rewrite disappoint?

In our view, in different ways.

Move first. Migrating first and modernizing later is sound for a data center exit. It disappoints when the second step is a promise rather than a funded item. In the illustration, emulating now and refactoring in years two and three totals 2.0 + 4.0 + 4.0 + (2 × 2.2) + (2 × 1.4) = $17.2 million over five years, the same as refactoring directly. The tie assumes the later refactor costs $4.0 million, not $5.0 million; at $5.0 million it is $18.2 million. Either way, the refactor needs a second approval; without one, the estate keeps its COBOL and its skills problem. GAO's July 2025 review found eight of the 11 federal legacy systems most in need of modernization use outdated programming languages; moving COBOL onto a new runtime doesn't change that.

Big-bang rewrite. AWS's strangler fig guidance says a big bang migration "introduces transformation risk and business disruption," and that while the application is being refactored, adding features is extremely hard or even impossible. We think boards underestimate that second point: the business waits years for change while paying for two systems. Replacing the system slice by slice, behind a routing layer, keeps the old one shrinking and lets each slice prove its savings. AWS notes the pattern needs code access and suits large monoliths; for small applications a rewrite might be more efficient.

What should a modernization plan contain?

GAO's June 2019 report, GAO-19-471, checked agency modernization plans for three elements: milestones, a description of the work, and the planned disposition of the legacy system. In July 2025, GAO-25-107795 scored 69 legacy systems on 16 attributes, including age, vendor support and operating cost. Of the 11 ranked most in need of modernization, agencies had plans for nine, and only three plans included all three elements. GAO warned that incomplete plans raise the likelihood of overruns, delays and failure.

In our view, disposition is the element business cases most often skip. A plan should say when the legacy system is switched off and what happens to its data, contracts and capacity, because that date is when the savings become real. We would add a fourth element: one-off and run cost for each path considered, so the choice is made on money and risk. On paying down technical debt, see funding technical debt as a portfolio item.

In our view, modernization choices stick when each application's disposition, cost and decommission date sit in the same operating model as the investment that funds them, so a slipped cutover shows up as money, not just as a late milestone.

Sources

Frequently asked questions

What are the 7 Rs of cloud migration?

As AWS Prescriptive Guidance lists them as of November 2026, the seven strategies are retire, retain, rehost, relocate, repurchase, replatform, and refactor or re-architect. Microsoft's Cloud Adoption Framework lists eight: retire, retain, rehost, replatform, refactor, rearchitect, rebuild and replace. Microsoft has no separate relocate, calls repurchase replace, and splits AWS's refactor into three strategies.

Is rehosting a mainframe a good first step?

It can be, if a data center exit forces speed and the application won't need to change soon. Microsoft says rehost suits a workload only if it stays unchanged for at least two years. Moving COBOL unchanged onto an emulation runtime is, in AWS's terms, replatform. In our view, moving first works only when the later modernization is funded too; otherwise the skills risk remains.

What is the difference between refactor and rearchitect?

In Microsoft's Cloud Adoption Framework, refactoring improves the internal structure of code without adding new features, while rearchitecting redesigns the workload's architecture for scalability, agility and service orientation. Rebuild goes further: full redevelopment using cloud-native services. AWS groups all of these under one strategy, refactor or re-architect, and calls it the most complex and costly option.

Why is a big-bang rewrite of a legacy system risky?

Because the old system runs at full cost until the new one is complete, and the business gets few new features in the meantime. AWS's strangler fig guidance calls big-bang migration a source of transformation risk and business disruption. Microsoft's mainframe refactor architecture says single-process conversion carries risk because conversion, data migration and testing must line up.

Free playbook

Make your organization legible to its people and its AI.

Read the playbook
Steve Elliott

Steve Elliott

Published November 23, 2026

More on Enterprise Architecture

Capability maps, TOGAF, rationalization.