---
title: "Mainframe Exit Savings and AI-Assisted COBOL Rewrites"
description: "AI can rewrite COBOL, but translation isn't migration. How to plan a mainframe modernization that cuts cost: spec first, dual-run, one job at a time."
url: https://axiointelligence.com/blog/cobol_modernization_with_ai
---

[← Blog](https://axiointelligence.com/blog)

mainframe, COBOL, modernization, AI

# How companies save millions leaving the mainframe, and why AI-assisted COBOL rewrites still need a plan

Brice Ayres / October 8, 2026

Short answer

Companies that move COBOL workloads off the mainframe report large savings: The New York Times' converted system costs 70% less a year to run, and the Air Force cut one system's annual cost from about $30 million to about $3 million. AI tools from Anthropic, AWS and IBM now make reading and converting COBOL much faster, but translating code is the easy part. The savings come from planning: knowing what each job does, writing it down as a spec, dual-running old and new, and moving one job at a time.

In February, Anthropic published a post saying its Claude Code tool could modernize COBOL. That day, [IBM’s stock fell 13.2%](https://www.reuters.com/business/ibm-posts-steepest-daily-drop-since-2000-after-anthropic-says-ai-can-modernize-2026-02-24/), its steepest one-day drop since October 2000.

Investors heard “AI can rewrite COBOL” and drew a straight line to the end of the mainframe. The reality is more useful, and less dramatic. AI really has changed the economics of COBOL modernization. But the companies saving millions aren’t the ones that pointed a model at their code and hit go. They’re the ones with a plan.

## Can AI rewrite COBOL code?

Yes, and it’s getting good at it. Three of the biggest players have shipped tools:

- **Anthropic** said Claude Code can map dependencies across large COBOL codebases, document workflows and surface risks that “would take human analysts months to surface,” according to [CNBC’s coverage](https://www.cnbc.com/2026/02/23/ibm-is-the-latest-ai-casualty-shares-are-tanking-on-anthropic-cobol-threat.html) of its post. The pitch: “Legacy code modernization stalled for years because understanding legacy code cost more than rewriting it. AI flips that equation.”
- **AWS Transform** handles IBM z/OS COBOL modernization. AWS says [customers are completing full transformation and testing of 250,000-line mainframe applications in six weeks](https://aws.amazon.com/blogs/migration-and-modernization/aws-transform-one-year-milestone/), and that its assessments find an average of 35% in compute and 45% in licensing savings.
- **IBM watsonx Code Assistant for Z** converts COBOL to Java. IBM Research reports its pipeline delivers [a median structural quality score of over 80% and a functional score above 75%](https://research.ibm.com/publications/enterprise-scale-cobol-to-java-translation-llms-augmented-with-program-analysis) on its test set.

So if you’re asking whether AI can convert COBOL to Java, the answer is yes. Notice what IBM’s own numbers say, though: a functional score above 75% means a meaningful share of the converted logic still needs work. That’s where the real project is.

## Translation isn’t migration

IBM’s response to the sell-off was self-interested, but it wasn’t wrong. As Rob Thomas, IBM’s SVP of software, [wrote](https://www.cio.com/article/4137185/anthropics-claim-that-ai-can-quickly-refactor-cobol-rattles-ibm-investors.html): “The modernization challenge is not a COBOL language problem. It is everything the application runs on and integrates with.”

[VentureBeat](https://venturebeat.com/technology/ibms-usd40b-stock-wipeout-is-built-on-a-misconception-translating-cobol-isnt) put the IBM view more bluntly, quoting a spokesperson: the real work is “data architecture redesign, runtime replacement, transaction processing integrity, and hardware-accelerated performance.”

In our experience, the hard parts of a mainframe migration are:

- **Data.** Db2, VSAM, IMS and flat files, with formats and encodings decades old.
- **Batch scheduling.** Hundreds of jobs with dependencies nobody has fully written down.
- **Integrations.** Partner feeds, EDI, reports that land in someone’s inbox every morning.
- **Business rules nobody remembers.** The tax edge case, the month-end exception, the hard-coded store number.

AI helps with all of these, especially the last one. But it doesn’t remove the need to understand them.

## How much can leaving the mainframe save?

Real examples, with numbers from the organizations and vendors involved:

- **The New York Times** moved a COBOL-based system to Java and later to AWS. It now [costs 70% less to operate per year](https://aws.amazon.com/blogs/apn/automated-refactoring-of-a-new-york-times-mainframe-to-aws-with-modern-systems/) than it did on the mainframe in 2015.
- **The U.S. Air Force** converted 1.3 million lines of COBOL to Java on AWS GovCloud. Per the [vendor case study](https://tsri.com/video-lowered-tco-by-90-cobol-to-java-on-aws-the-u-s-air-force-s-modernization/), annual cost went from $30 million to about $3 million.

You don’t have to move everything to start saving. As we covered in [what actually sets your z/OS software bill](https://axiointelligence.com/blog/zos_peak_software_cost), IBM’s monthly software charges usually follow the busiest four hours of the month. Moving the right batch jobs out of that window can lower the bill well before a full migration.

## A mainframe modernization plan that works

This is the approach we use. It’s slower than “convert everything,” and much less likely to fail.

### 1\. Inventory and rank

List every job, what it reads, what it writes and who depends on it. Rank by dollars, meaning share of the cost peak, and by risk. Start where dollars are high and risk is low.

### 2\. Write the spec before the code

For each job you move, write down what it does: inputs, outputs, rules, rounding, edge cases, error handling. AI is very good at drafting this from COBOL source. A person who knows the business has to check it. The spec, not the old code, becomes the source of truth.

### 3\. Let AI do the heavy lifting

Use AI to read the COBOL, draft the spec, generate the new code and write tests. This is where the time savings are real.

### 4\. Verify independently

Build a check that doesn’t come from the same place as the new code, such as a separate model of the spec or reconciliation against real historical outputs. Plant known bugs and make sure your checks catch them.

### 5\. Dual-run

Run the new job alongside the old one every cycle and compare outputs record by record, including month-end and year-end, until they match.

### 6\. Cut over one job at a time

Turn off the old job only after the outputs match and the people downstream sign off. Then do the next one.

## When to bring in a mainframe modernization consultant

You probably need outside help if:

- Your COBOL experts are retiring and nobody is shadowing them
- You’ve tried a big-bang migration and it stalled
- You want AI to do the conversion work but don’t have a way to prove the results are right
- Your licensing bill keeps climbing and you don’t know which jobs drive it

## How we help

We’re a small, senior team that does AI-assisted COBOL modernization the careful way: spec first, independent verification, dual runs, one job at a time. We work alongside your mainframe team, not around them.

See our [mainframe migration services](https://axiointelligence.com/services/mainframe-migration), or [book a call](https://axiointelligence.com/book) to talk through which jobs would save you the most to move first.

## We do this work for a living.

A 30-minute scoping call with the engineers who would do the work.

[Book a scoping call](https://axiointelligence.com/book)

Or email [contact@axiointelligence.com](mailto:contact@axiointelligence.com?subject=Project%20inquiry) and we’ll reply.

## Related posts

Oct 16, 2026

### [AWS Mainframe Modernization Is Closed to New Customers. Here's What a Mainframe Exit Looks Like Now](https://axiointelligence.com/blog/aws_mainframe_modernization_closed_alternatives)

AWS Mainframe Modernization closed to new customers on July 30, 2026. What changed, what current customers keep, and realistic mainframe exit paths now.

mainframe, COBOL, AWS

Oct 1, 2026

### [What actually sets your z/OS software bill](https://axiointelligence.com/blog/zos_peak_software_cost)

z/OS software cost is set by the busiest four hours of the month. How the rolling 4-hour peak works, and how to move the batch behind it.

mainframe, z/OS, COBOL

Oct 18, 2026

### [On-Prem LLM vs Frontier API: When Self-Hosting Pays Off](https://axiointelligence.com/blog/on_prem_llm_vs_frontier_api)

Most companies shouldn't run an on premise LLM to save money. Here are the four cases where self-hosting does pay off, and the costs people miss.

LLM, AI, on-premise
