Stoyan Mitov is the CEO of Dreamix, a custom software development company helping tech leaders increase capacity without giving up quality.gettyAlmost every new project request at our company now includes AI or data optimization. McKinsey's 2026 Global Tech Agenda found that half of the surveyed companies ranked AI as their top investment priority. However, the infrastructure most organizations depend on for daily operations was built for a different era and struggles to support what AI actually needs to function.Over the past years working across heavily regulated industries, including aviation, healthcare and logistics, we've repeatedly seen how clients invest in a promising AI pilot and then hit a wall connecting it to their core legacy systems. The integration work often consumes more engineering effort than the AI solution itself.To be fair, legacy systems aren't inherently bad. Many have been reliable for decades. The challenge comes when those systems need to interact with AI workloads that demand real-time data, modern APIs and continuous data pipelines—capabilities that simply weren't on the table when these platforms were designed.The Scope Of The ProblemMcKinsey's 2026 research on CIO budgets found that most organizations were already operating at the edge of their change capacity, with the bulk of technology spending going toward keeping existing systems running. A 2024 McKinsey report noted that as much as 70% of the software Fortune 500 companies were using was built at least 20 years prior.​Gartner Inc. predicted in June 2025 that over 40% of agentic AI projects would be canceled by the end of 2027, citing escalating costs, unclear business value and inadequate risk controls. Deloitte's Tech Trends 2026 research also stated that most agents still relied on conventional APIs and data pipelines that create bottlenecks.​​There's also a security dimension. IBM's 2025 Cost of a Data Breach Report found that 97% of organizations that experienced an AI-related security incident lacked proper AI access controls. In legacy environments, where monitoring capabilities and access controls tend to be weaker, these risks compound.​What Actually WorksModernization is meaningfully less expensive than it was even a few years ago. The 2024 McKinsey report noted that a large transaction processing system that would have cost well over $100 million to modernize a few years ago can now be done for less than half that, in part due to AI-assisted development tools. From what we've observed across our projects, four things consistently separate the efforts that deliver value from those that don't.Start With The Business Problem, Not The TechnologyThe most successful projects we've been part of begin with the following question: What specific decision or process will AI improve, and how will we measure that? This sounds obvious, but many organizations skip it. They align around a technology choice before they have alignment on the problem.In practice, this means involving operations leads, front-line staff and compliance stakeholders before a single line of code is written. In aviation, for example, a client wanted AI to reduce delays during irregular operations. The real problem, once we dug into it, was that dispatchers lacked a single view of real-time aircraft status. The AI solution was straightforward once that was clear. Without that clarity up front, the project would've been built on the wrong foundation.Replace Rather Than Add LayersMcKinsey's research on CIO budgets distinguished "deliberate modernizers," who set aside at least one-third of their budget for change and actively retire legacy components, from "strained transformers," who bolt new tools onto existing systems without shrinking the legacy footprint. Deliberate modernizers tend to keep infrastructure run costs at least 20% lower than peers over time.The practical implication is that each new service should be designed to retire something, not coexist with it indefinitely. When we scope a modernization project, we ask clients to name what will be decommissioned as a result. If the answer is nothing, the total cost of ownership will keep growing, and the oldest layer in the stack will limit AI performance.Bring Front-Line Staff In EarlyLegacy systems are full of business logic that exists only in code nobody documented. Edge cases, work-arounds and validation rules that were added years ago for reasons no one remembers are invisible to architects reviewing documentation or diagrams. The people who use these systems daily are the ones who catch them.We've learned to run structured working sessions with front-line users before and during migration, not just at the testing phase. In one healthcare project, an early workshop with clinical staff surfaced a data-entry work-around that had been in place for six years. Had we discovered it at go-live, it would've meant weeks of rework. Finding it early saved the project.Move Incrementally And Plan For What You'll LearnThe projects that fail most consistently are the ones targeting a single sweeping migration. The ones that succeed move piece by piece, with clear criteria for what success looks like at each stage before moving to the next.Incremental delivery also makes the transition more manageable for the teams affected. Staff absorb change better in stages. Each completed phase builds confidence internally and provides the real-world data needed to make better decisions about what comes next.What Leaders Should ExpectNone of this is simple, and I'm skeptical of anyone who frames modernization as a straightforward win. It's expensive, disruptive and carries real risk. Some legacy systems genuinely don't need to be replaced right now.However, the pressure is building. AI investment is accelerating, and the talent pool for legacy technologies is thinning as the engineers who built these systems approach retirement, often taking undocumented knowledge with them. Also, younger engineers tend to prefer modern technology stacks. Maintaining a legacy system that few people want to work on while trying to hire AI talent creates a tension that gets worse each year. Security requirements are tightening. The longer modernization is postponed, the more technical debt accumulates, and the harder the eventual transition becomes.For organizations serious about their AI strategy, treating legacy modernization as a prerequisite rather than a separate initiative is, I think, the best way to approach it.​Forbes Technology Council is an invitation-only community for world-class CIOs, CTOs and technology executives. Do I qualify?