Deutsche Bahn automates code migration to S/4HANA | NTT DATA

Thu, 23 July 2026

Deutsche Bahn automates SAP ECC code migration to S/4HANA

Modernize

custom applications in weeks rather than months

Reduce

technical risk with precise, automated code adaptation

Support

long-term success with a clean-core strategy and cloud readiness

Summary

For Deutsche Bahn, migrating its SAP landscape to S/4HANA is a business-critical initiative. One of the greatest challenges was transforming its extensive custom code during the phased migration of multiple applications. More than 15.3 million lines of ABAP code needed to be adapted quickly, consistently and with minimal risk. With smartShift’s automation approach and NTT DATA’s SAP expertise, Deutsche Bahn significantly accelerated its transformation, minimized technical risks and laid the foundation for a modern, maintainable and cloud-ready SAP landscape.

Business need

Extensive custom code complicates migration to SAP S/4HANA

Deutsche Bahn’s SAP landscape has grown over decades, incorporating specialized processes, many interfaces and a large volume of custom developments. Through the Argo initiative, the company aims to prepare its IT landscape for the future. By the end of SAP ECC maintenance in 2027, key systems in finance, procurement and vehicle and infrastructure maintenance must be transformed to SAP S/4HANA.

When the initiative began, it quickly became clear that the success of the transformation depended heavily on modernizing custom code. To keep business innovation moving, custom developments had to be stable, compatible with SAP S/4HANA and ready to support future requirements.

The challenge was less about the complexity of individual changes than the scale of the transformation. In total, 234,000 objects and more than 15 million lines of code had to be analyzed, assessed and optimized for SAP S/4HANA. Deutsche Bahn also wanted to eliminate technical debt, remove unused developments and improve standards. Migration was the first step in achieving the larger goal of laying the foundation for a modern, maintainable and cloud-ready SAP environment.

Using internal and external ABAP developers to adapt the code manually would have been too slow and too risky. The potential for inconsistencies, prolonged testing cycles and even unstable target systems was simply too high.

With this solution, we not only automated the adaptations required for SAP S/4HANA but also sustainably modernized our custom code. The significant reduction in technical debt provides long-term stability and future readiness.”

Dr Florian Hoffmann Senior SAP S/4HANA Project Manager, Deutsche Bahn

Solution

Automation meets SAP expertise

Deutsche Bahn needed partners that could combine deep SAP expertise with scalable automated methods to deliver a secure, fast, high-quality and consistent migration.

smartShift provided a highly automated technology platform for analysis, transformation and modernization, while NTT DATA contributed the functional and process expertise required to integrate changes effectively into business and technical operations.

Automation played a critical role in completing the project at scale. It made it possible to comprehensively analyze the entire code base, implement required changes with precision while incorporating modernization measures, such as improvements in performance, security and maintainability.

Automated dual maintenance kept ongoing enhancements synchronized across legacy and target systems without disruptive code freezes. This allowed Deutsche Bahn to continue running business-critical processes reliably while moving toward SAP S/4HANA at speed.

The value of this approach became clear early in the program. The transformation of custom developments in the first systems was completed in weeks, significantly faster than is typical for projects of this scale. And the quality of the code base improved considerably. Much of the technical debt was remediated, unused objects were automatically removed and existing code was selectively modernized.

Despite the large number of changes, testing effort remained low, highlighting the stability and reliability of the automated results.

NTT DATA supported Deutsche Bahn with deep process and transformation expertise for the functional adjustments required for multiple project streams, so automation and business requirements worked together seamlessly.

Fixed-price and fixed-schedule delivery models provided predictable outcomes, reliable service-level agreements, and clear timelines and cost structures. This delivered a high level of planning certainty in Deutsche Bahn’s complex organizational environment.

Outcomes

Fast and secure transformation for the SAP future

At the time of writing, 11 systems had been successfully transformed and the first SAP S/4HANA systems were already running in production. Feedback on the Argo initiative has made it clear that the combination of automation, SAP expertise and a structured delivery approach increased speed, reduced risk and established the foundation for sustainable modernization.

Deutsche Bahn has successfully moved to SAP S/4HANA, benefiting from a significantly more stable, streamlined and future-oriented SAP code base that will serve as a strong foundation for years to come.

Key results include:

Transformation completed in weeks instead of months

On average, adapting custom code for each system required only four weeks, significantly faster than traditional methods.

Precise adaptation of 15.3 million lines of code

smartShift analysis identified 863,000 findings within the existing code base. Approximately 57,000 of these related to necessary adjustments for SAP HANA and S/4HANA. Most findings related to broader modernization initiatives, such as security improvements, performance optimization and the implementation of new ABAP Cloud standards.

Sustainable custom code cleanup

A total of 14,984 unused objects were removed automatically and safely. This represents a major step toward clean core principles and cloud readiness.

High quality standards

Despite the extensive changes, only 20 testing tickets were assigned to the Code Conversion team. This exceptionally low number significantly reduced testing effort.

A strategic partner by your side

NTT DATA and smartShift supported Deutsche Bahn as experienced partners, combining automation capabilities and deep SAP expertise. This enabled internal teams to focus on core business activities and project coordination, while external specialists supported the stability, quality and sustainable modernization of the SAP landscape.

Through this collaborative partnership, Deutsche Bahn accelerated its SAP S/4HANA transformation, modernized its technical foundation and established a stable, future-oriented SAP code base for the future.


Latest Case Studies

How can we help you

Get in touch