NHS closes GitHub repositories over AI security risks
May 5, 2026

NHS England is temporarily making public repositories private. The case shows how AI-assisted code analysis is changing public-sector open-source strategy.
What this is about
NHS England has told technology leaders to temporarily make public GitHub repositories private. According to The Register, repositories must be walled off by May 11, 2026 while the organization assesses how strongly new AI models can analyze code, architecture notes and configuration details.
This is not a routine product story. It exposes a real clash between two security instincts: public code supports transparency and reuse, while powerful AI tools can scan large codebases for weaknesses, patterns and misconfigurations much faster than human teams.
What the measure actually does
In practice, repositories that used to be public are expected to become internally visible only, unless there is an explicit and exceptional reason to keep them open. The Register quotes internal guidance saying public repositories can unintentionally disclose source code, architectural decisions, configuration details and useful context.
NHS England describes the move as a temporary cybersecurity measure. What remains unclear is how long the restriction will last and which specific attacks it is meant to prevent. That uncertainty is exactly why the case matters: many organizations will face the same question without a simple answer.
Why it matters
The UK government standard has long said that code built with public money should generally be open and reusable. The NHS Service Manual also treats open source as a way to reduce duplicated work and supplier lock-in.
AI does not automatically overturn that logic, but it changes the cost curve. A human team needs time to read scattered repositories. A model can summarize patterns, old libraries, internal naming conventions or attack paths in minutes. Whether closing already published repositories meaningfully reduces that risk is disputed. Former NHSX open-technology lead Terence Eden argues that interesting public code may already have been mirrored, archived or copied into training datasets.
In plain language
Imagine a city library publishing hospital blueprints so other cities can build better clinics. Suddenly there is a scanner that marks every weak door and poorly protected window in seconds. The library can lock the plans away, but that only helps so much if many copies are already in circulation.
A practical example
A public healthcare agency runs 300 repositories: 180 documentation projects, 70 internal tools, 30 data pipelines and 20 small web applications. Only five contain risky configuration clues. An AI system finds those five in one hour, while a traditional audit would take two weeks.
The best response is not necessarily to make everything private. A stronger process would combine secret scanning, architecture review, dependency audits, clear exceptions for reusable public code and a publishing standard that treats AI-assisted analysis as a normal threat.
Scope and limits
- Closed code is not automatically safer. Vulnerabilities do not disappear because fewer people can see them.
- Code that was already public may exist in archives, forks or training data.
- For public institutions, transparency still has real value: taxpayers, suppliers and other agencies benefit from reusable code.
The NHS case is therefore not proof against open source. It is a warning that open-source governance in 2026 must distinguish more carefully between transparency, supply-chain security and AI-assisted attacker analysis.
SEO & GEO keywords
NHS England, Open Source, GitHub repositories, AI security, Mythos, public sector software, cybersecurity, UK government service manual, software supply chain, healthcare IT
💡 In plain English
The NHS is temporarily putting public code repositories behind a wall because strong AI models can scan code for weaknesses faster. That does not solve the problem by itself, but it shows that open source needs updated security rules.
Key Takeaways
- →NHS England reportedly plans to temporarily privatize public GitHub repositories by May 11, 2026.
- →The rationale is that AI models can analyze code, architecture and configuration faster.
- →The move clashes with UK open-source policy for publicly funded software.
- →Already published code may still exist in forks, archives or training datasets.
- →Secret scanning, dependency audits and clear publishing rules are more useful than blanket closure.
FAQ
Does this mean open source is unsafe?
No. Public code is not automatically unsafe. Risk rises when repositories expose secrets, architecture clues or unaudited dependencies.
Does privatizing old repositories help?
Only partly. Code that was already public may have been mirrored, archived or included in training data.
What should public agencies do now?
They should define publishing processes, secret scanning, dependency audits and clear exceptions for reusable public code.