R&D Tax Relief for AI Companies: Can AI Agents, LLMs and AI Software Qualify?

As more UK businesses develop AI agents, machine learning models and other AI-powered software, understanding how R&D tax relief applies has become increasingly important.

However, one of the biggest misunderstandings among founders of AI companies is that building an AI product automatically qualifies for R&D tax relief.

Unfortunately, that isn't how the legislation works and HMRC doesn't see it that way.

R&D tax relief for AI companies

Whether you're developing AI agents, computer vision software, voice AI, Retrieval-Augmented Generation (RAG) systems or AI-powered SaaS platforms, HMRC is interested in how you managed to solve the technological problems - not simply the fact that your software uses artificial intelligence.

Some AI companies invest hundreds of thousands of pounds developing sophisticated products only to discover that little of the work qualifies for R&D tax relief. Others assume they do not qualify because they're using existing models such as GPT, Claude or Gemini. However, in reality significant parts of their development may satisfy HMRC's requirements.

Understanding the distinction could make a substantial difference to the amount of relief your business can claim.

In this guide we'll explain:

  • what R&D tax relief for AI companies actually means;
  • why some AI development qualifies while other projects do not;
  • how HMRC approaches AI and software development;
  • practical examples of qualifying and non-qualifying activities; and
  • common mistakes we see AI startups make.

Whether you're building AI agents, AI SaaS platforms, machine learning tools or other innovative software, this guide will help you understand how the UK's R&D tax relief rules apply.

What Qualifies as R&D for AI Companies?

One of the biggest misunderstandings surrounding R&D tax relief for AI companies is that a project qualifies simply because it involves artificial intelligence. In reality, HMRC doesn't assess whether your business is developing AI.

Instead, it considers whether your activities meet the statutory definition of Research and Development (R&D) for tax purposes.

The definition of R&D is contained in section 1006 Income Tax Act 2007, which provides that the meaning of R&D follows generally accepted accounting practice, as modified by the Department for Science, Innovation and Technology (DSIT) Guidelines on the Meaning of Research and Development for Tax Purposes.

These Guidelines have statutory force and form the basis on which HMRC determines whether a project constitutes qualifying R&D.

Once it has been established that a project meets this definition, the Corporation Tax legislation then determines whether the company is entitled to relief and which expenditure qualifies under the relevant R&D tax relief provisions.

How the DSIT Guidelines Apply to AI Companies

Unfortunately, the DSIT Guidelines on the Meaning of Research and Development for Tax Purposes do not contain a simple checklist that determines whether a project qualifies for R&D tax relief.

Instead, they set out a series of principles that must be considered together. Every project turns on its own facts and circumstances, but for most AI companies the question can be distilled into four key principles.

If your project satisfies these principles, it may constitute qualifying Research and Development for tax purposes. If it does not, the fact that it involves artificial intelligence or machine learning is unlikely to be enough in isolation.

Let's look at each principle in turn.

1. Was the project seeking an advance in science or technology?

The starting point is whether the project sought to achieve an advance in science or technology.

The DSIT Guidelines explain that an advance means extending the overall knowledge or capability within a field of science or technology. It is not enough simply to improve your own knowledge or develop a new commercial product using existing techniques.

This distinction is particularly important for AI companies.

Many businesses build innovative products by combining existing AI models, APIs and cloud services in novel ways. Whilst the resulting software may be commercially successful, that does not necessarily mean the underlying development constitutes qualifying R&D.

By contrast, if your development requires new methods of solving recognised technological problems that cannot readily be achieved using existing knowledge, there may be an advance in technology.

AI example

A company develops a customer support platform using an existing Large Language Model and publicly available APIs.

Whilst the finished product may be highly innovative from a commercial perspective, simply integrating existing technologies is unlikely, on its own, to represent an advance in science or technology.

However, if the same company develops a novel orchestration framework that enables multiple AI agents to collaborate reliably in real time whilst maintaining context, reducing latency and preventing conflicting outputs, that work may be much more likely to satisfy this requirement.

2. Did the project involve technological uncertainty?

Perhaps the most important concept within the DSIT Guidelines is technological uncertainty.

A technological uncertainty exists where a competent professional working in the relevant field could not readily determine how to achieve the desired technological objective.

In other words, there must be genuine doubt about whether a particular technological solution is possible, or how it can be achieved.

This is very different from commercial uncertainty.

For example, uncertainty over whether customers will buy your product, whether investors will fund your business or whether the project will generate a profit does not qualify.

The uncertainty must relate to the underlying technology.

AI example

Examples of technological uncertainty in AI development may include:

  • developing a reliable multi-agent architecture capable of coordinating autonomous decision-making;
  • reducing hallucinations without significantly increasing response times;
  • enabling persistent long-term memory across multiple user sessions;
  • improving inference efficiency whilst maintaining acceptable accuracy; or
  • designing new methods of evaluating and selecting AI model outputs in real time.

These are the types of engineering challenges that may indicate genuine technological uncertainty, provided they could not readily be resolved using existing knowledge.

3. Could the uncertainty be readily resolved by a competent professional?

The DSIT Guidelines make clear that not every difficult problem constitutes R&D.

The question is whether a competent professional working in the relevant field could have readily resolved the uncertainty using the existing state of knowledge.

If the answer is yes, the work is unlikely to qualify.

If experienced software engineers genuinely needed to investigate, prototype and evaluate different technical approaches because no obvious solution existed, this is much more likely to indicate qualifying R&D.

For AI companies, this often involves demonstrating:

  • why existing frameworks or published techniques were insufficient;
  • what alternative technical approaches were considered;
  • why those approaches were rejected or refined; and
  • how the final solution was ultimately achieved.

It is also worth remembering that an R&D project does not have to succeed in order to qualify. The legislation is concerned with the process of attempting to achieve an advance in science or technology by resolving technological uncertainty. 

Projects that ultimately fail—or where one or more technical approaches prove unsuccessful—may still constitute qualifying R&D, provided the statutory conditions are satisfied.

4. Was the uncertainty addressed through a process of systematic investigation?

Finally, qualifying R&D generally involves systematic investigation, analysis and testing aimed at resolving the technological uncertainty.

The work should follow a structured process rather than consisting of ad hoc experimentation.

For many AI startups, this process may already form part of their normal software development lifecycle.

Examples of supporting evidence include:

  • software architecture documentation;
  • technical specifications;
  • Git repositories and commit histories;
  • issue tracking systems;
  • sprint planning and retrospectives;
  • prototype testing;
  • benchmark and evaluation reports
  • model performance metrics; and
  • design decisions explaining why particular technical approaches were adopted or rejected.

Maintaining contemporaneous records not only strengthens an R&D claim but also makes it significantly easier to demonstrate how technological uncertainties were identified and resolved should HMRC request further information.

How AI Companies Can Qualify for R&D Tax Relief

One of the most important points to remember is that artificial intelligence is not a special category of R&D.

The same statutory principles apply whether a company is developing:

  • AI agents;
  • machine learning models;
  • Retrieval-Augmented Generation (RAG) systems;
  • computer vision software;
  • voice AI;
  • cybersecurity platforms;
  • fintech software; or
  • traditional business applications.

The fact that a project uses AI is neither sufficient to establish qualifying R&D nor a reason to deny relief.

Instead, each project must be assessed on its own facts by asking a simple question:

Did the company seek to achieve an advance in science or technology by resolving technological uncertainties through a process of systematic investigation?

If the answer is yes, there may be qualifying R&D.

If the answer is no, the project is unlikely to qualify regardless of how innovative or commercially successful the product may be.

Applying the Principles: Real-World AI Development Examples

Having considered the statutory definition of R&D and the principles contained within the DSIT Guidelines, the next question is:

How do these rules apply to real AI development projects?

Unfortunately, there is no definitive list of qualifying or non-qualifying activities. Every project must be considered on its own facts.

However, the following examples illustrate how the statutory principles are likely to apply in practice.

Example 1 – Building a Simple AI Chatbot

A software company develops an internal customer support chatbot using an existing Large Language Model (LLM) through a commercially available API.

The development work includes:

  • writing prompts;
  • integrating the API into an existing application;
  • connecting the chatbot to the company's knowledge base; and
  • designing the user interface.
Is this likely to qualify?
Probably not.

Although the finished product may deliver significant commercial benefits, the company is primarily applying existing technology using well-established techniques.

There is unlikely to be any technological uncertainty that could not readily be resolved by a competent software engineer using publicly available documentation and existing development frameworks.

This is perhaps the most common misconception we encounter.

Using artificial intelligence is not the same as undertaking qualifying Research and Development.

Example 2 – Developing a Multi-Agent Architecture

Now consider a different company.

Rather than deploying a single LLM, it is developing an autonomous system consisting of multiple specialist AI agents.

Each agent performs a different function:

  • planning;
  • research;
  • validation;
  • coding;
  • quality assurance; and
  • final decision making.

The engineering challenge lies in enabling these agents to collaborate efficiently whilst:

  • maintaining context;
  • preventing conflicting outputs;
  • allocating tasks dynamically;
  • avoiding unnecessary duplication; and
  • achieving acceptable response times.
Is this more likely to qualify?
Potentially, yes.

Assuming these challenges involve genuine technological uncertainty that cannot readily be resolved using existing knowledge, the company may be seeking an advance in software engineering rather than simply applying existing AI tools.

The fact that the project uses AI agents is not what makes it qualifying.

Instead, it is the technological challenges involved in designing and implementing the underlying architecture that may satisfy the statutory definition of R&D.

Example 3 – Fine-Tuning an Existing AI Model

Many AI companies fine-tune existing foundation models using their own proprietary datasets. Whether this constitutes qualifying R&D depends entirely on the nature of the work undertaken.

Scenario A

The company follows published documentation to fine-tune an existing model using standard techniques.

The process is straightforward and produces the expected results.

Unlikely to qualify.
Scenario B

The company encounters fundamental technical challenges when attempting to improve model performance for highly specialised tasks.

Multiple approaches are investigated before a workable solution is identified.

The engineers develop new optimisation techniques that significantly improve accuracy whilst maintaining commercially acceptable inference costs.

Potentially qualifying.

Again, the distinction lies not in the use of AI, but in whether genuine technological uncertainty existed.

Example 4 – Retrieval-Augmented Generation (RAG)

Retrieval-Augmented Generation (RAG) has become one of the most popular methods of improving AI accuracy by combining Large Language Models with external knowledge sources.

Many companies now implement RAG systems.

However, implementation alone is unlikely to qualify.

Where R&D may arise

Suppose a company develops entirely new methods of:

  • selecting relevant documents;
  • ranking retrieved information;
  • reducing hallucinations;
  • maintaining context across multiple retrieval stages; or
  • improving response quality whilst reducing latency.

If these challenges involve overcoming technological uncertainty through systematic investigation, they may represent qualifying R&D.

Simply following an existing RAG framework or tutorial is much less likely to do so.

Example 5 – Prompt Engineering

Prompt engineering has become an increasingly important discipline within AI development.

However, prompt engineering does not automatically constitute qualifying R&D.

For example:

Experimenting with different prompts to improve customer responses is unlikely to represent an advance in science or technology.

By contrast, developing entirely new prompting methodologies that solve recognised technological limitations may require further consideration.

The key question remains exactly the same:

What technological uncertainty was being resolved?

Example 6 – AI Coding Assistants

AI coding assistants such as GitHub Copilot, Cursor, Claude Code and Amazon Q Developer are changing the way software is written.

Many AI startups now incorporate these tools into their development processes or build products that use AI to generate, review or improve code.

However, using an AI coding assistant does not automatically constitute qualifying R&D.

Scenario A – Using AI to Write Code

A software company uses GitHub Copilot or Cursor to help developers write application code more efficiently.

The AI assists with tasks such as:

  • generating boilerplate code;
  • suggesting functions;
  • writing unit tests;
  • explaining existing code; and
  • identifying potential bugs.
Is this likely to qualify?
No.

Although these tools may significantly improve developer productivity, they are simply being used as development aids.

The company is using existing technology to accelerate software development rather than seeking an advance in science or technology.

The use of AI during the development process does not, by itself, create qualifying R&D.

Scenario B – Developing a New AI Coding Platform

Now consider a company developing its own AI-powered coding assistant.

The objective isn't simply to generate code, but to solve complex engineering challenges such as:

  • understanding large codebases across multiple repositories:
  • maintaining project-wide architectural consistency;
  • reducing inaccurate or insecure code suggestions;
  • automatically identifying dependencies across complex software systems; and
  • generating reliable code whilst minimising hallucinations.

The development team investigates multiple technical approaches, builds prototypes and systematically evaluates different methods before achieving an acceptable solution.

Is this more likely to qualify?
Potentially, yes.

The fact that the product is an AI coding assistant is not what makes the project qualifying.

Instead, the relevant question is whether the company is attempting to overcome genuine technological uncertainties through a process of systematic investigation.

If the project seeks to achieve an advance in software engineering—for example, by developing novel methods of code analysis, context management or AI-assisted software generation—it may satisfy the statutory definition of R&D.

Key Point

Whether you're using an AI coding assistant or building one are two very different questions.

Using existing AI tools to improve developer productivity is unlikely to constitute qualifying R&D in its own right.

However, developing innovative AI coding technologies that extend the current state of software engineering may well involve the sort of technological advances and uncertainties contemplated by the DSIT Guidelines.

Example 7 – Reducing AI Hallucinations

Hallucinations remain one of the biggest engineering challenges in AI, with no universally accepted solution despite rapid advances in model architecture and retrieval techniques.

Suppose an AI company develops new techniques that significantly reduce hallucinations without materially increasing inference time or reducing model accuracy.

The development requires:

  • extensive experimentation;
  • multiple prototype architectures;
  • bespoke evaluation frameworks; and
  • systematic testing.
Could this qualify?

Quite possibly.

Reducing hallucinations often involves addressing genuine technological uncertainty rather than merely implementing existing technology.

If the company is extending technological capability through systematic investigation, these activities may satisfy the statutory definition of R&D.

The Same Technology Can Produce Different Outcomes

Perhaps the most important lesson from these examples is that there is no such thing as "AI R&D" simply because AI is involved.

Two companies may use exactly the same foundation model, cloud infrastructure and software tools.

One may be carrying out qualifying R&D.

The other may not.

The difference lies in the nature of the technological challenges being addressed, rather than the technologies themselves.

That is why every claim should be assessed on its own facts and why careful documentation of the technological uncertainties encountered during development is so important.

The table below provides a general indication of how the statutory R&D principles may apply to common AI development activities. Every project must be assessed on its own facts.

AI Development Activity Likely to Qualify? Reason
Integrating ChatGPT or another Large Language Model (LLM) Usually No Primarily applying existing technology using established techniques.
Developing a multi-agent AI architecture Potentially May involve overcoming genuine technological uncertainty in software engineering.
Fine-tuning an existing AI model Depends Routine fine-tuning is unlikely to qualify, but developing novel optimisation techniques may.
Implementing a standard Retrieval-Augmented Generation (RAG) solution Usually No Following established frameworks is unlikely to represent an advance in science or technology.
Developing new RAG retrieval or ranking techniques Potentially May involve creating new methods of solving recognised technological problems.
Prompt engineering Usually No Optimising prompts alone is generally an application of existing technology.
Developing an AI coding assistant Depends Using AI coding tools is unlikely to qualify, but developing new AI-assisted coding technologies may.
Reducing AI hallucinations using novel techniques Potentially May involve genuine technological uncertainty and systematic investigation.

Common Mistakes AI Companies Make When Claiming R&D Tax Relief

As AI technology evolves, many founders assume that developing an AI-powered product automatically means they qualify for R&D tax relief.

In reality, the legislation has not changed simply because artificial intelligence has become more sophisticated. The same statutory principles continue to apply, regardless of whether your company is developing AI agents, machine learning models, computer vision software or more traditional software applications.

Below are some of the most common misconceptions we encounter.

Mistake 1 – Assuming all AI development qualifies

Perhaps the biggest misconception is that incorporating artificial intelligence into a product automatically creates qualifying R&D.

It doesn't.

Simply integrating an existing Large Language Model (LLM), calling a commercial API or deploying an open-source framework is unlikely, on its own, to constitute qualifying Research and Development.

The focus should always be on the technological challenges your team sought to overcome, not the technologies you happened to use.

Mistake 2 – Confusing commercial innovation with technological innovation

Many AI products are genuinely innovative from a commercial perspective.

However, the statutory definition of R&D is concerned with advances in science or technology, not whether a product is commercially successful.

A software platform may transform an industry yet involve little or no qualifying R&D if it simply combines existing technologies in a novel commercial way.

Conversely, software that appears relatively straightforward to customers may involve significant technological advances behind the scenes.

Mistake 3 – Failing to document technological uncertainty

Many AI companies carry out qualifying R&D without maintaining sufficient evidence to support a claim.

Good documentation should explain:

  • the technological objective;
  • the uncertainties encountered;
  • why those uncertainties could not readily be resolved by a competent professional;
  • the approaches investigated;
  • the testing undertaken; and the conclusions reached.

Technical design documents, architecture diagrams, Git repositories, issue trackers, sprint documentation and testing records can all provide valuable supporting evidence.

Mistake 4 – Waiting until the year-end to consider R&D

One of the best ways to strengthen an R&D claim is to identify qualifying projects as they progress, rather than attempting to reconstruct the technical narrative many months later.

Recording key decisions and technical challenges contemporaneously is usually far easier than relying on memory after the project has been completed.

Mistake 5 – Focusing only on the finished product

HMRC is interested in how the technological challenges were addressed.

The development process is often more important than the final software itself.

Projects that ultimately fail, or where several technical approaches prove unsuccessful, may still constitute qualifying R&D if the statutory conditions are satisfied.

Key Takeaways

If you're developing AI software, don't assume your project automatically qualifies for R&D tax relief.

Equally, don't assume it cannot qualify simply because you're using existing AI models or commercially available tools.

The critical question is whether your company sought to achieve an advance in science or technology by resolving technological uncertainties through systematic investigation and testing, as described in the DSIT Guidelines.

For many AI companies, the answer will depend on the nature of the engineering challenges involved rather than the use of artificial intelligence itself.

That is why every project should be assessed on its own facts.

Frequently Asked Questions

Does building an AI agent automatically qualify for R&D tax relief?

No.

Simply developing an AI agent does not automatically constitute qualifying Research and Development for tax purposes. The relevant question is whether your project sought to achieve an advance in science or technology by resolving technological uncertainties through a process of systematic investigation.

Does using ChatGPT or another Large Language Model qualify for R&D tax relief?

Not by itself.

Using commercially available AI models such as ChatGPT, Claude or Gemini is unlikely to constitute qualifying R&D if you're simply applying existing technology.

However, if your company is developing new techniques to overcome technological challenges - for example improving orchestration, reducing hallucinations or developing novel memory architectures - the underlying development work may qualify.

Can a pre-revenue AI startup claim R&D tax relief?

Potentially, yes.

There is no requirement for a company to be profitable before claiming R&D tax relief. Many innovative AI businesses undertake significant research and development before generating meaningful revenue.

The availability and value of relief will depend on the company's circumstances and the applicable legislation for the relevant accounting period.

Can failed AI projects still qualify?

Yes.

A project does not need to be commercially successful—or even technically successful—to qualify.

The legislation recognises that genuine R&D often involves investigating approaches that ultimately prove unsuccessful. What matters is that the company sought to resolve technological uncertainties through systematic investigation.

Does prompt engineering qualify?

Usually, though not automatically.

Experimenting with prompts or refining prompts to improve responses will often represent the application of existing technology rather than an advance in science or technology.

However, projects involving genuinely new methods of prompting that overcome recognised technological limitations should be considered on their own facts.

Does fine-tuning an existing AI model qualify?

It depends.

Following established fine-tuning techniques using publicly available methods is unlikely, by itself, to constitute qualifying R&D.

Where a company develops new approaches to overcome technological uncertainty or significantly advances the state of software engineering, qualifying R&D may arise.

Can cloud computing costs be included in an R&D claim?

Potentially.

Following changes to the legislation, certain data licence and cloud computing costs may qualify where the statutory conditions are met and the expenditure is directly attributable to qualifying R&D activities.

The rules are detailed and should be considered carefully as part of any claim.

Should we document our development work?

Absolutely.

One of the most common reasons R&D claims encounter difficulties is because businesses fail to document the technological challenges they encountered during development.

Keeping contemporaneous records of objectives, uncertainties, testing and technical decisions makes preparing a claim significantly easier and provides valuable evidence should HMRC request further information.

Final Thoughts

Artificial intelligence is transforming the way software is designed, developed and deployed, but it hasn't changed the legal principles that determine whether a company qualifies for R&D tax relief.

The fact that your business develops AI software, AI agents or machine learning solutions does not automatically mean your activities constitute qualifying Research and Development. Equally, using existing AI models or third-party APIs does not prevent a claim where your team is genuinely seeking to overcome technological uncertainties.

Every project should be assessed on its own facts.

For many AI companies, the most important questions are not:

  • "Are we using AI?"
  • "Have we built an AI agent?"

Instead, they are:

  • Were we seeking an advance in science or technology?
  • Did we encounter genuine technological uncertainty?
  • Could that uncertainty readily have been resolved by a competent professional?
  • Did we undertake a process of systematic investigation to resolve it?

Answering these questions correctly is the foundation of a robust R&D claim.

As artificial intelligence continues to evolve, we expect AI businesses to undertake increasingly complex development projects involving areas such as multi-agent systems, Retrieval-Augmented Generation (RAG), computer vision, autonomous workflows, robotics and advanced machine learning. Whilst the underlying technologies may change rapidly, the statutory definition of R&D remains firmly rooted in these principles.

Understanding them—and documenting your development work effectively—will place your business in the strongest possible position when preparing an R&D claim.

How The Friendly Accountants Can Help

Determining whether an AI project qualifies for R&D tax relief is rarely straightforward.

Two businesses developing similar products can reach completely different conclusions depending on the technological challenges they faced and how those challenges were addressed.

That's why we encourage AI founders to discuss their projects before assuming they either qualify - or don't.

An early conversation can often help identify the technological advances, uncertainties and development activities that are most relevant to an R&D claim. Where appropriate, we can also advise whether HMRC's Advance Assurance process may be available and suitable for your business.

If you're developing AI software, AI agents, machine learning platforms or other innovative technology and would like to discuss how the R&D legislation applies to your business, we'd be delighted to have an informal conversation.

Even if you're not yet ready to submit a claim, understanding the rules at an early stage can help you document your development work more effectively and avoid common pitfalls as your business grows.

Disclaimer: This article provides general guidance based on the legislation and HMRC practice at the date of publication. Whether a particular AI development project qualifies for R&D tax relief depends on its specific facts and circumstances. Professional advice should always be obtained before submitting an R&D claim.

For more useful information, check out our Ebooks here.

And if you'd like to know how we can help you with all of this, or with anything else, feel free to give us a call on 01202 048696 or email us at [email protected].

Alternatively, please feel free to complete our Business Questionnaire here.

About the author

Richard Baldwyn

I’ll help you legally pay less tax, using insider knowledge gained from my time as a former tax inspector—insight most accountants simply don’t have. More about Richard and the TFA team

{"email":"Email address invalid","url":"Website address invalid","required":"Required field missing"}
>