The hidden cost of AI-generated code: when saving developer hours costs you more
AI coding tools save developer hours up front and move the cost into review, rework and security. What the research measures, and when it costs you more.

Table of contents
AI-generated code is a little like having a machine that can suddenly double the speed of a factory. At first, the savings look obvious. More products are made in less time, and the workers appear more productive. But if quality control, inspection, and maintenance stay at the old pace, the factory quickly fills with products that still need to be checked. The bottleneck has not disappeared, it has simply moved.
AI coding tools can create the same effect in software development. They can help developers produce code faster, but every additional line still needs to be reviewed, tested, secured, integrated, and maintained. If those processes cannot keep up, the hours saved during coding can reappear as hours spent fixing problems later. The question, then, is not simply whether AI makes developers faster. It is whether the entire software development process can absorb that extra output without creating new costs.
AI coding tools can help developers complete tasks faster. Randomised trials involving 4,867 developers at Microsoft, Accenture, and a Fortune 100 company found that developers using an AI coding assistant completed 26.08% more tasks.
However, the time saved on individual tasks does not necessarily translate into lower costs across an entire project. Research into GitHub projects adopting Cursor found that the initial increase in development speed was temporary. At the same time, static analysis warnings and code complexity continued to increase.
AI-generated code can also create more work later in the development process. Across 8.1 million pull requests, AI-authored pull requests took 4.6 times longer to be picked up for review. They were accepted 32.7% of the time, compared with 84.4% for manually authored pull requests.
This can create a hidden trade-off. Developers may spend less time writing code, but more time reviewing, correcting, testing, and maintaining it. If those additional costs are not accounted for, the apparent saving from AI can disappear.
Key takeaways
- AI coding tools can produce real productivity gains at the task level. Randomised trials covering 4,867 developers found a 26.08% increase in completed tasks when developers used an AI coding assistant. The benefit becomes less straightforward when looking at an entire project.
- Research into projects that adopted Cursor found that the initial increase in development velocity was temporary. Static analysis warnings and code complexity, however, remained elevated. This suggests that faster code production can come with additional maintenance and quality costs.
- Some of the work also shifts into code review. AI-authored pull requests waited 4.6 times longer to be picked up for review. They were accepted 32.7% of the time, compared with 84.4% for manually written pull requests.
- Delivery can also become less predictable. CircleCI telemetry covering 28.7 million workflows found that median feature-branch throughput increased by 15%, while main-branch throughput fell by 7%. Main-branch success also fell to 70.8%.
- Google's DORA research points in a similar direction. Its research found that AI adoption is associated with higher software delivery throughput, but also with lower delivery stability.
- Security is another concern. A peer-reviewed study found that approximately 40% of 1,689 programs generated by GitHub Copilot contained vulnerabilities. This means generated code still requires careful security review before it can be trusted.
- The potential savings are also significant because developer time is expensive. In May 2025, the mean hourly wage for software developers in the US was $71.20, before overheads. When AI-generated code creates additional review, testing, debugging, or maintenance work, those costs can quickly reduce the value of the hours initially saved.
In this article
- Does AI-generated code really save money?
- Where the saved hours go
- What the research measures and what it does not
- When AI-generated code costs more than it saves
- How to capture the saving without paying it back later
- How RocketDevs fits
- Conclusion
- FAQ
Does AI-generated code save money?
At the task level, AI-generated code can save time and money. At the level of software that actually ships and continues to work, the picture is more complicated. The key question is whether a company's development and delivery processes can absorb the additional code AI produces. Current evidence suggests many teams are not fully equipped to do this yet.
AI coding tools are already widely used. JetBrains' 2026 survey of more than 15,000 professional developers found that 90% use AI coding agents at least weekly, while 68% use them daily. Google's DORA research found a similar level of adoption, with 90% of respondents reporting that they use AI at work. More than 80% said that AI has increased their productivity.
The increase in AI-assisted development is also visible in platform data. GitHub's Octoverse reports that an average of 43.2 million pull requests were merged each month, up 23% year on year. It also recorded more than 1 million pull requests created by coding agents between May and September 2025.
The productivity gain itself is real. Three randomised field experiments at Microsoft, Accenture, and a Fortune 100 company studied 4,867 developers. The resulting Management Science study found a 26.08% increase in completed tasks among developers using an AI coding tool. Less experienced developers also had higher adoption rates and saw greater productivity gains.
DORA found a similar relationship at the organisational level. Its research linked AI adoption with higher software delivery throughput and better product performance. This supports the idea that AI can help teams produce more software in less time.
However, higher output does not automatically mean lower costs. The same DORA research found a negative relationship between AI adoption and software delivery stability. Developers also reported concerns about the reliability of AI-generated code, with 30% saying they had little or no trust in the code produced by AI.
For a founder, the important question is therefore not simply whether AI makes code faster to write. It is where the saved time goes afterwards. If AI-generated code requires more review, testing, debugging, or maintenance, some of the initial saving can reappear elsewhere in the development process.
The result is a simple distinction: AI can reduce the cost of producing code without necessarily reducing the cost of delivering reliable software.
Where do the saved hours go?
The saved hours can move into review, rework, debugging, and recovery. These costs happen later in the development pipeline, so they may not be immediately recognised as a consequence of AI-generated code. Instead, they can simply look like slower engineering or an increasingly difficult delivery process.
Consider the journey a code change takes through a typical development pipeline. A developer writes the code, opens a pull request, waits for review, goes through testing, merges the change, and deploys it. Sometimes the change then needs to be rolled back or fixed. AI can speed up the initial coding step, but it does not remove the need for human judgement further down the pipeline.
The review queue.
LinearB's benchmark of 8.1 million pull requests from 4,800 organisations found that AI-generated pull requests waited 4.6 times longer before review. Once picked up, however, they were reviewed twice as quickly. The same analysis found that AI-generated pull requests had a much lower acceptance rate than manually written pull requests: 32.7% compared with 84.4%. A rejected pull request still consumes developer and reviewer time, even though the code ultimately does not ship.
Debugging and verification.
Developers also report that AI-generated code can take longer to check and fix. Stack Overflow's 2025 survey found that 45.2% of developers said debugging AI-generated code is more time-consuming. Another 66% identified output that is "almost right, but not quite" as their biggest frustration.
Sonar's survey of more than 1,100 developers found that AI accounted for 42% of committed code. However, 96% of developers said they do not fully trust AI-generated code to be functionally correct. Only 48% said they always check AI-generated code before committing it, while 38% said reviewing it takes more effort than reviewing a colleague's work.
This creates a verification gap. AI can produce code faster than developers can confidently verify it. When that happens, the bottleneck simply moves from writing code to checking it.
The main branch.
CircleCI analysed 28,738,317 workflows run on its platform in September 2025. For the median team, feature-branch throughput increased by 15%, but main-branch throughput fell by 7%. In other words, more work was being started while less work was successfully making it through the main development branch.
The stability of that main branch also declined. CircleCI reported that main-branch success rates fell to 70.8%, the lowest level in more than five years. Recovery took 72 minutes for the typical team, which was 13% longer than the previous year.
Accumulated quality debt.
Some costs appear even later. A 2026 Carnegie Mellon study compared GitHub projects that adopted Cursor with similar projects that did not. The researchers found a large but temporary increase in development velocity after adoption. They also found a persistent increase in static analysis warnings and code complexity.
Those warnings and increased complexity were not simply cosmetic problems. The researchers found that they contributed to a long-term slowdown in development velocity. In other words, some of the speed gained from AI-generated code can eventually be consumed by the additional complexity that developers have to maintain.
The financial impact becomes easier to see when developer time is given a monetary value. The US Bureau of Labor Statistics puts the mean hourly wage for software developers at $71.20 as of May 2025, before benefits and other overheads.
That means a pull request that takes days to review, gets rejected, and then has to be rewritten has already consumed expensive engineering time. A main branch that is failing 29.2% of the time can also create costs across an entire team because developers may be blocked from completing their own work.
The central issue is therefore not whether AI saves an hour of coding. It is whether the organisation saves money after every hour of review, testing, debugging, maintenance, and recovery has been counted.
What does the research measure and what does it not?
The research on AI coding tools can appear contradictory because different studies measure different parts of the development process. Some measure how many tasks developers complete. Others measure how long a task takes. Some look at what happens to code quality over a longer period. None of these studies measures the complete cost of producing and maintaining software over its lifetime. This is why different studies can reach different conclusions without necessarily contradicting one another.
| Study | Design | Sample | Finding |
|---|---|---|---|
| Cui et al., Management Science | Three randomised field experiments | 4,867 developers | 26.08% more completed tasks, with the largest gains among less experienced developers |
| METR, 2025 | Randomised controlled trial | 16 experienced developers, 246 tasks | Tasks took 19% longer with AI, while developers believed they were 20% faster |
| He et al., MSR 2026 | Difference-in-differences against matched projects | Cursor-adopting GitHub projects | Temporary increase in velocity, followed by a persistent rise in warnings and code complexity |
| DORA, 2025 | Survey | Nearly 5,000 technology professionals | Positive relationship with throughput, but negative relationship with delivery stability |
| CircleCI, 2026 | Workflow telemetry | 28,738,317 workflows | Feature-branch throughput increased, while main-branch throughput and success declined |
The difference becomes clearer when you look at what each study actually measured. The field experiments involving 4,867 developers measured completed tasks over a defined period. Much of the work was well scoped, and the largest productivity gains were seen among less experienced developers. METR's 2025 trial looked at a different group: 16 experienced developers working on mature open-source projects they already knew well. In that study, developers took 19% longer to complete tasks when they were allowed to use AI, even though they expected to be faster and later believed that AI had made them faster.
The studies were therefore looking at different situations. One measured the number of tasks completed by developers using AI. Another measured how long experienced developers took to complete specific tasks. A third examined how projects changed over time after adopting an AI coding tool. It is more useful to think of these as different photographs of the same development process rather than as competing answers.
The difference between actual performance and perceived performance is particularly important for founders relying on developer feedback. METR's developers believed they were working faster even though the measured results showed that they were taking longer. This suggests that self-reported productivity may not always reflect the actual time required to complete work.
The same issue can appear with security. A Stanford user study found that participants using an AI assistant produced less secure code than participants without one. They were also more likely to believe that the code they had written was secure. Developers may therefore feel more productive or confident without necessarily producing better results.
Measuring AI's impact is also becoming more difficult as developers become increasingly dependent on these tools. METR's 2026 follow-up study involved 57 developers, 143 repositories, and more than 800 tasks. It estimated an 18% speedup for developers returning to familiar projects and a 4% speedup for new developers. However, the confidence intervals for both estimates crossed zero, meaning the researchers could not establish a clear effect from their data.
METR also reported that between 30% and 50% of developers said they had chosen not to submit some tasks because they did not want to complete them without AI. The researchers concluded that their study design was probably not a good measure of AI's real-world productivity impact. Once developers change their behaviour because the tool is available, creating a clean comparison becomes much harder.
Industry data provides another perspective, although it should be treated as descriptive rather than causal evidence. GitClear analysed 623 million code changes and found that block duplication increased from 40.3 per million changed lines in 2023 to 73.0 in 2026 so far. At the same time, moved code, which can indicate refactoring, fell to 3.8% of changed lines. Because GitClear's data is observational and the company sells code analysis products, these results show a correlation rather than proving that AI caused the changes.
Another study analysed 3.52 million changes in a single enterprise codebase. It found that AI-generated C++ code had higher levels of interface and coupling burdens. These were associated with greater review effort and a 5–8% increase in compute resource consumption. The study also found that targeted developer feedback reduced targeted static analysis warnings by 11.1%.
That final finding is important because it suggests that AI-related technical debt is not necessarily unavoidable. The right development processes can reduce some of the problems created by generated code. Better review, testing, feedback, and monitoring can therefore affect the eventual cost.
What the research still does not provide is the number a founder would ultimately want: the total cost of a shipped feature when AI is involved. That figure would need to include the initial development time as well as review, testing, debugging, security work, incidents, maintenance, and rework over a much longer period.
Until research measures that complete cost, there is no single number that tells us exactly how much money AI coding tools save or cost. The evidence instead points to a broader pattern: AI can increase development output, but the financial benefit depends on what happens to that output after the code has been generated.
When does AI-generated code cost more than it saves?
AI-generated code can cost more than it saves when the amount of code being produced grows faster than a team can review and verify it. The risk becomes even greater when that code involves security or difficult engineering problems. DORA's research on delivery stability and studies of AI-generated code both point to these as important conditions.
Security is one area where the hidden cost of AI-generated code can become a serious and measurable problem. Pearce, Ahmad, Tan and Dolan-Gavitt tested GitHub Copilot against 89 scenarios involving high-risk security weaknesses. They generated 1,689 programs and found that approximately 40% were vulnerable. The study was conducted on an earlier generation of AI coding tools, but more recent research has found similar concerns.
Cotroneo, Improta and Liguori compared more than 500,000 Python and Java samples and found that AI-generated code contained more high-risk security vulnerabilities. Veracode's analysis of more than 100 large language models found that 45% of generated code samples failed its security tests. Veracode sells security testing services, so its findings should be considered alongside independent research. However, its results point in the same direction as the peer-reviewed studies.
The other major condition is task difficulty. In a preregistered experiment involving 758 consultants, Dell'Acqua and colleagues found that participants using AI were 19% less likely to reach a correct answer when working on tasks outside the model's effective capabilities. This matters for software development because not every programming task is a simple, well-defined problem.
Architecture decisions can depend on the history of a codebase. Concurrency problems can involve interactions that are difficult to see from a single function. Complex systems can also contain constraints that are not obvious from the code being edited. These are the kinds of situations where generating more code does not necessarily mean making progress faster.
| Situation | Likely net effect | Why | What to do |
|---|---|---|---|
| Well-scoped features, strong tests, fast review | Saves money | Task completion rises and the development pipeline can absorb the additional output | Use AI freely and monitor main-branch success |
| Output rising, review capacity flat | Costs more | AI pull requests wait 4.6x longer and most are rejected | Budget reviewer time before increasing code generation |
| Security-sensitive code | Costs more | Around 40% of generated programs were vulnerable in peer-reviewed testing | Require security review and scanning for AI-authored changes |
| Mature codebase, experienced team, hard problems | Unclear to negative | Experienced developers were measured as 19% slower in an RCT | Let senior engineers decide when AI is appropriate |
| Associates generating most of the code | Saves now, costs later | Productivity gains were largest among less experienced developers, while warnings and complexity persisted | Pair AI use with senior review and track warning trends |
The net-effect column is our interpretation of the cited research. It does not represent a measured threshold from any individual study.
AI does not make code cheap. It makes writing cheap, and then sends the bill to whoever has to trust the result.
The pattern across these findings is capacity. DORA's research describes AI as an amplifier. Without strong automated testing, mature version control practices, and fast feedback loops, an increase in the amount of code being produced can lead to greater instability.
Teams with these systems in place may be able to capture more of the productivity gain. Teams without them may find that the additional output creates more work than it removes.
If you want the longer version of the technical-debt argument, our article on the AI technical debt crisis explores how AI-generated code can create problems that appear later in the development lifecycle. For a closer look at why AI coding agents can produce more code than teams actually need, AI coding agents are writing too much code examines the behaviour behind these numbers.
How do you capture the saving without paying it back later?
The way to keep the savings from AI-generated code is to increase verification capacity as code generation increases. That means measuring the entire development pipeline rather than focusing only on how quickly developers can write code.
The order matters because each step addresses a different point where the productivity gain can be lost.
- Measure main-branch health before expanding AI use:
Track your main-branch success rate, recovery time, and how long pull requests wait for review. CircleCI reported a 70.8% main-branch success rate for its median team in 2025. Your own baseline matters more than the industry figure. Measure where you are before increasing AI use, then compare the results afterwards.
- Budget review time explicitly:
If AI increases the amount of code being produced, reviewer capacity needs to increase with it. Otherwise, pull requests will simply spend longer waiting in the queue. Set a clear expectation for review turnaround and make sure the team has enough capacity to meet it.
- Gate AI-authored changes with automated checks:
Run static analysis, automated tests, and security scanning on every pull request. Research by He and colleagues found that increases in warnings and code complexity contributed to longer-term development slowdowns. Another enterprise study found that targeted developer feedback reduced targeted static analysis warnings by 11.1%.
- Require security review for sensitive code:
Code involving authentication, payments, data access, or customer-facing functionality should receive appropriate security checks regardless of whether it was written by a developer or generated by AI. The author of the code does not remove the security risk.
- Pair less experienced developers with senior reviewers:
Less experienced developers have been found to gain more productivity from AI coding tools. They may also need more support identifying subtle errors in generated code. Senior review can help teams capture the productivity benefit without allowing mistakes to move further through the development process.
- Track trends rather than snapshots:
A temporary increase in development velocity does not necessarily translate into a lasting improvement. Monitor warnings, code complexity, main-branch success, and change failure rates over time. Reviewing these measures quarterly can reveal problems that would be easy to miss in a single measurement.
None of this means slowing development down. The goal is to use some of the time AI gives back to strengthen the parts of the process that still require human judgement. If generation becomes faster while verification stays the same, the productivity gain can turn into a backlog. If verification keeps pace, more of the time saved by AI can become a genuine business saving.
Where RocketDevs fits
The expensive part of AI-generated code is not producing it. It is verifying it. As AI increases the amount of code a team can generate, the need for engineers who can review that code, test it, identify problems, and know when to reject it becomes more important.
That is where RocketDevs fits. Every RocketDevs developer completes 6–8 hours per developer of assessment before reaching a client. This means you are adding engineering and verification capacity before the first pull request reaches your team.
Rates start at $9.99/hr for Associate developers, $21.99/hr for Mid-senior developers, and $30.99/hr for Senior developers. Adding experienced engineers to review AI-assisted work can help prevent the rework and technical debt that can otherwise eat into the time AI was supposed to save. RocketDevs also offers a 14-day risk-free trial, giving you an opportunity to assess whether the additional engineering capacity works for your team.
Elite Talent. Honest Price.
If your team is shipping more code than it can confidently verify, you can build a vetted development team with RocketDevs. If you are also considering the cost of getting an engineering hire wrong, read about what a bad engineering hire can cost a seed-stage startup. You can also learn more about how to evaluate AI-assisted code in an interview.
Conclusion
AI coding tools can make developers faster. The research shows that clearly. Developers can complete more tasks, generate code more quickly, and increase the amount of work moving into the development pipeline.
But writing code is only one part of building software.
Think of AI as giving your development team a much faster printing press. You can produce pages of code in a fraction of the time. That sounds like an obvious saving until you realise that someone still has to read every page, check that the information is correct, find the mistakes, test it, and make sure the final document is safe to publish.
If the printing press becomes ten times faster but your editors remain just as fast, you have not created a tenfold productivity gain. You have created a much larger pile of documents waiting to be checked.
That is the challenge with AI-generated code. The cost does not necessarily disappear when a developer spends less time writing. It can move into code review, debugging, testing, security checks, maintenance, and recovery from failures. Research has found productivity gains at the task level, while other studies have found slower experienced developers, persistent increases in code complexity, longer review queues, and weaker delivery stability.
This does not mean companies should avoid AI coding tools. It means they need to measure the right thing. A developer completing a coding task faster is useful information, but it is not the same as knowing whether the business delivered reliable software more cheaply.
The real opportunity comes from building a development process that can handle the additional output. Automated testing can catch problems earlier. Static analysis can identify issues before they become technical debt. Security scanning can reduce the risk of vulnerable code reaching production. Senior developers can provide judgement where AI struggles. Teams can also monitor the health of the main branch instead of assuming that more generated code means more productive development.
The goal is not to slow AI down. It is to make the rest of the system fast enough to benefit from it.
AI can give you a faster engine. But if you don't upgrade the brakes, the faster car is not saving you money. It's just getting you to the crash sooner.
Frequently asked questions
Does AI-generated code create technical debt?
It can. A difference-in-differences study of GitHub projects that adopted Cursor found a persistent increase in static analysis warnings and code complexity. The researchers also found that these increases contributed to a long-term slowdown in development velocity. However, the problem is not necessarily unavoidable. An enterprise study found that targeted developer feedback reduced targeted static analysis warnings by 11.1%.
Is AI-generated code less secure?
It can be, particularly when it is not thoroughly reviewed. A peer-reviewed study found that approximately 40% of 1,689 programs generated by Copilot were vulnerable. Another user study found that developers using an AI assistant produced less secure code while also being more likely to believe their code was secure. AI-generated code should therefore receive appropriate security review, particularly when it involves sensitive systems or data.
Do AI coding tools make developers faster?
At the task level, they often do. Randomised trials involving 4,867 developers found a 26.08% increase in completed tasks when developers used an AI coding tool. However, the results vary depending on the developer and the type of work. A separate randomised trial found that experienced developers working in mature codebases took 19% longer when using AI. A causal study of Cursor adopters also found that project-level velocity gains were temporary.
How should a startup budget for AI coding tools?
Budget for the verification work as well as the AI tools themselves. AI-generated pull requests waited 4.6 times longer for review and were accepted at a much lower rate than manually written pull requests. A realistic AI coding budget should therefore account for reviewer time, automated testing, security scanning, and maintenance. Tracking main-branch stability can then help determine whether the additional output is producing a genuine saving.
Can AI-generated code actually reduce development costs?
Yes, but faster code generation does not automatically mean cheaper software development. AI can reduce the time needed to complete individual coding tasks, but some of that saving can be offset by additional review, testing, debugging, security checks, and maintenance. The real cost saving depends on whether your team can increase its verification capacity as AI increases the amount of code being produced.
James Hitch, COO at RocketDevs.LinkedIn
Sources
Cui, Demirer, Jaffe, Musolff and Peng, The Effects of Generative AI on High-Skilled Work, Management Science
He, Miller, Agarwal, Kästner and Vasilescu, Speed at the Cost of Quality, MSR 2026
Google Cloud, Announcing the 2025 DORA Report
CircleCI, 2026 State of Software Delivery report
METR, Measuring the Impact of Early-2025 AI on Experienced Open-Source Developer Productivity
METR, We are Changing our Developer Productivity Experiment Design, 2026
Stack Overflow Developer Survey 2025, AI
Sonar, State of Code Developer Survey, January 2026
Pearce, Ahmad, Tan and Dolan-Gavitt, Asleep at the Keyboard?, IEEE S&P 2022
Perry, Srivastava, Kumar and Boneh, Do Users Write More Insecure Code with AI Assistants?, ACM CCS 2023
Cotroneo, Improta and Liguori, Human-Written vs. AI-Generated Code, ISSRE 2025
Veracode, 2025 GenAI Code Security Report
GitClear, The Maintainability Gap: 2026 AI Code Quality Research
Tran et al., Characterizing the Quality Profile of AI-Generated C++ in Production, arXiv 2608.06640
Dell'Acqua et al., Navigating the Jagged Technological Frontier, Organization Science
US Bureau of Labor Statistics, software developers hourly mean wage
JetBrains Research, AI coding agent adoption 2026
GitHub, Octoverse 2025

Written by
James Hitch
COO
James Hitch is the COO of RocketDevs, where he runs sales, recruiting, and the vetting operation that accepts only the top 2–3% of developer applicants. He cares about putting accessible, elite engineering talent within reach of founders and startups worldwide, at a fair price. He writes about technical hiring, building AI-native engineering teams, and how startups can access elite developers affordably.
More from our blog
Continue exploring insights and stories from RocketDevs
