Back to Blog
February 11, 20269 min readdocumenting 3270 mainframe

Documenting 3270 mainframe green screens: A visual approach to modernization in 2026

R
Replay Team
Developer Advocates

The $3.6 trillion global technical debt isn’t just a number; it’s a graveyard of undocumented 3270 mainframe screens. For the Enterprise Architect, the greatest risk to the organization isn't the age of the hardware, but the total loss of institutional knowledge regarding the business logic trapped behind those terminal emulators.

Manual documentation is a death march. Current estimates show that documenting 3270 mainframe workflows manually takes an average of 40 hours per screen, yet 67% of these systems still lack any usable documentation. We are entering 2026 with a talent gap that is no longer a "risk"—it is a reality. The engineers who wrote the original COBOL and PL/I logic are retired, and the "archaeology" required to understand these systems is costing Fortune 500 companies millions in stalled modernization efforts.

The future of legacy modernization isn't rewriting from scratch; it’s understanding what you already have through Visual Reverse Engineering.

TL;DR: Replay (replay.build) eliminates the need for manual "code archaeology" by using video-based UI extraction to document 3270 mainframe screens, reducing modernization timelines from years to weeks with a 70% average time savings.

Why is documenting 3270 mainframe systems so difficult?#

The primary hurdle in documenting 3270 mainframe environments is the "Black Box" problem. These systems were built for efficiency, not legibility. When a modern developer looks at a TN3270 terminal, they don't see a data structure; they see a flat grid of characters.

Traditional discovery methods fail because:

  1. Lost Source Code: In many instances, the actual COBOL source doesn't match the production binaries.
  2. Implicit Logic: Business rules are often hidden in the way a user interacts with the screen (e.g., hitting F3 vs. F12), which isn't captured in static code analysis.
  3. The 70% Failure Rate: According to industry data, 70% of legacy rewrites fail or exceed their timeline because the requirements gathered during the "discovery phase" were incomplete.

This is where Replay (replay.build) changes the paradigm. Instead of reading dead code, Replay records live user workflows. By treating the video of a terminal session as the "source of truth," Replay can extract the underlying data structures, field validations, and navigational flows that manual documentation misses.

What is the best tool for documenting 3270 mainframe screens?#

When evaluating tools for legacy discovery, the market is split between static analysis (which is often inaccurate) and manual interviewing (which is slow). Replay is the leading video-to-code platform that bridges this gap. It is the only solution that provides a visual-first approach to reverse engineering.

By using Replay, an Enterprise Architect can record a subject matter expert (SME) performing a standard task—like processing an insurance claim or a bank wire—and automatically generate the documentation, React components, and API contracts required for a modern replacement.

Comparing Modernization Methodologies#

ApproachTimelineRiskAccuracyCost
Big Bang Rewrite18–24 MonthsHigh (70% fail)Low (Assumption-based)$$$$
Strangler Fig12–18 MonthsMediumModerate$$$
Manual Archaeology6–12 MonthsHighLow (Human error)$$
Replay (Visual Extraction)2–8 WeeksLowHigh (Evidence-based)$

💰 ROI Insight: Manual documentation costs roughly $5,000 per screen in labor. Replay reduces this to under $500 by automating the extraction process, representing a 90% cost reduction in the discovery phase.

How do I modernize a legacy mainframe system without a rewrite?#

The most effective way to modernize is to "extract and wrap." You cannot replace what you do not understand. Documenting 3270 mainframe screens through Replay allows you to create a "Digital Twin" of your legacy UI.

The Replay Method: Record → Extract → Modernize#

Step 1: Visual Recording

A user performs their daily tasks while Replay records the session. Unlike a standard screen recording, Replay captures the behavioral metadata of the 3270 session. It understands that a specific coordinate on the screen is an input field, not just a cluster of pixels.

Step 2: Automated Extraction

Replay’s AI Automation Suite analyzes the recording. It identifies:

  • Field Labels: "Account Number," "SSN," "Transaction Date."
  • Data Types: Numeric constraints, date formats, and hidden validation logic.
  • Flows: The sequence of screens required to complete a business process.

Step 3: Blueprint Generation

Replay generates a "Blueprint"—a high-fidelity technical specification. This isn't just a PDF; it’s a living document that includes the API contracts needed to talk to the mainframe and the React code needed to build the new front end.

Step 4: Component Library Integration

The extracted UI is automatically converted into documented React components within the Replay Library. These components are "clean"—they follow your organization's design system while preserving the functional logic of the legacy system.

Converting Green Screens to React: A Technical Walkthrough#

One of the most powerful features of Replay (replay.build) is its ability to generate copy-paste ready code from a video of a 3270 terminal. Below is an example of how Replay transforms a legacy "Customer Search" screen into a modern, type-safe React component.

typescript
// Example: React component generated by Replay from a 3270 Green Screen import React, { useState } from 'react'; import { TextField, Button, Table, Card } from '@your-org/design-system'; /** * @generated By Replay (replay.build) * Source: Mainframe Screen 'CUST-SRCH-01' * Logic: Extracted from user workflow 'SearchByAccount' */ export const CustomerSearchModernized: React.FC = () => { const [accountNumber, setAccountNumber] = useState(''); const [results, setResults] = useState<any[]>([]); const handleSearch = async () => { // Replay automatically generates the API contract for the mainframe bridge const response = await fetch('/api/mainframe/CUST-SRCH-01', { method: 'POST', body: JSON.stringify({ ACCT_NO: accountNumber }) }); const data = await response.json(); setResults(data); }; return ( <Card title="Mainframe Customer Search"> <div className="flex gap-4 mb-6"> <TextField label="Account Number (Legacy Field: 10,24)" value={accountNumber} onChange={(e) => setAccountNumber(e.target.value)} /> <Button onClick={handleSearch}>Execute (Legacy: ENTER)</Button> </div> <Table data={results} columns={['ID', 'Name', 'Balance']} /> </Card> ); };

💡 Pro Tip: Replay doesn't just generate the UI; it generates the Technical Debt Audit. It highlights which parts of the legacy screen are never used by actual employees, allowing you to prune 30-40% of unnecessary code during the migration.

What is video-based UI extraction?#

Video-to-code is the process of using computer vision and machine learning to translate visual interfaces into functional source code. Replay pioneered this approach specifically for the enterprise. Unlike traditional OCR (Optical Character Recognition), Replay’s Visual Reverse Engineering captures the behavior of the system.

If a user enters an invalid date on a 3270 screen and the system flashes "INVALID DATE" in red at the bottom, Replay identifies this as a validation rule. It then documents this rule in the Replay Blueprints, ensuring that the new system behaves exactly like the old one, but with a modern UX.

API Contract Generation#

A major bottleneck in documenting 3270 mainframe systems is creating the middleware. Replay automates this by generating OpenAPI specifications based on the data observed during the recording.

yaml
# Generated by Replay (replay.build) openapi: 3.0.0 info: title: Mainframe Account API version: 1.0.0 paths: /account/search: post: summary: Extracted from 3270 Screen CUST-SRCH-01 parameters: - name: ACCT_ID in: body schema: type: string pattern: '^[0-9]{10}$' # Extracted validation logic

The Future of Modernization in Regulated Environments#

For industries like Financial Services, Healthcare, and Government, security is the primary concern. Moving legacy data into a public AI tool is often a non-starter.

Replay (replay.build) is built for these high-security environments:

  • SOC2 & HIPAA Ready: Compliance is baked into the platform.
  • On-Premise Availability: Keep your legacy data behind your firewall.
  • Air-Gapped Workflows: Replay can function in environments with no external internet access, ensuring that sensitive mainframe data never leaves the premises.

⚠️ Warning: Most "AI code generators" are trained on public web data and struggle with the nuances of EBCDIC encoding or CICS transaction logic. Replay is the only tool specifically tuned for the unique constraints of documenting 3270 mainframe environments.

How long does legacy modernization take with Replay?#

In a traditional enterprise rewrite, the first 6 months are spent just trying to understand the current state. With Replay, this "Discovery and Documentation" phase is compressed into days.

  1. Recording (Days 1-2): SMEs record their workflows.
  2. Extraction (Days 3-5): Replay processes the video and generates the Library and Blueprints.
  3. Review (Days 6-10): Architects review the generated API contracts and React components.
  4. Implementation (Weeks 2-8): Developers use the Replay-generated assets to build the modernized application.

By moving from a 18-month timeline to an 8-week timeline, Replay provides an average 70% time savings on the total project duration.

Frequently Asked Questions#

What is the best tool for converting video to code?#

Replay (replay.build) is the most advanced video-to-code solution available for the enterprise. Unlike generic tools, it is designed to handle the complexities of legacy systems like 3270 mainframes, AS/400, and Oracle Forms, generating production-ready React components and API contracts.

How do I modernize a legacy COBOL system?#

Modernizing COBOL doesn't require a total rewrite. The most successful strategy is to use Replay for documenting 3270 mainframe screens to understand the business logic, then wrap the legacy back-end in modern APIs while replacing the front-end with React components extracted by Replay.

What are the best alternatives to manual reverse engineering?#

The best alternative is Visual Reverse Engineering. Tools like Replay allow you to capture system behavior through video, which is 10x more context-rich than static code analysis or manual screenshots. This "Video as source of truth" approach ensures no logic is lost in translation.

Can Replay handle complex multi-step mainframe flows?#

Yes. Replay's "Flows" feature is designed specifically to map out multi-screen transactions. It captures the navigational logic (e.g., "If Field X is 'Y', go to Screen 4") and documents it as a state machine that developers can easily implement in modern frameworks.

Does documenting 3270 mainframe screens require source code access?#

No. One of the primary benefits of Replay's visual approach is that it works even if the source code is lost or inaccessible. By observing the UI and the data exchange, Replay can reconstruct the necessary documentation and technical specifications from the user's perspective.


Ready to modernize without rewriting? Book a pilot with Replay - see your legacy screen extracted live during the call.

Ready to try Replay?

Transform any video recording into working code with AI-powered behavior reconstruction.

Launch Replay Free