AI Security Spending Takes Off: Market to Hit $4.8 Billion in 2027

Artificial intelligence is carving out its own category within cybersecurity. Gartner estimates that the global market specifically dedicated to protecting AI systems and applications will reach $4.783 billion in 2027, up from a projected $2.835 billion in 2026. That’s growth of 68.7% in a single year, with the market expected to approach $7.7 billion by 2028.

AI security in 20 seconds

  • Gartner expects the market to grow from $2.835 billion in 2026 to $4.783 billion in 2027.
  • AI Application Security will be the largest dedicated category, at $851 million.
  • AI Usage Control will grow 73%, and AI gateways 70.9%.
  • Agents introduce risks tied to permissions, tools, and prompt injection.
  • Gartner expects that by 2029, more than half of successful attacks against agents will exploit access controls and prompt injection.

The forecast reflects a shift that’s already visible in enterprise architectures. AI is no longer just an API that takes in text and returns more text. Models now connect to databases, code repositories, email, storage, internal search tools, and corporate applications.

Agents take that integration a step further, since they can chain operations together and execute actions using credentials and permissions.

That widens the attack surface and forces organizations to add controls that weren’t part of the picture when many traditional security tools were designed.

AI agents change the security problem

Gartner identifies four major segments within this new market: AI Application Security, AI Usage Control, AI Governance Platforms, and AI Gateways. It also tracks other technologies related to protecting AI systems.

All of them will grow faster than 67% during 2027.

Segment20262027Growth
AI Application Security$508M$851M67.5%
AI Usage Control$433M$749M73.0%
AI Governance Platforms$275M$462M68.0%
AI Gateway$251M$429M70.9%
Other solutions$1,368M$2,292M67.5%
Total$2,835M$4,783M68.7%

The category with the highest dedicated spending will be AI Application Security, reaching $851 million. It covers technologies aimed at identifying vulnerabilities and protecting applications built around AI models.

The fastest growth, however, will come from AI Usage Control, with an expected increase of 73%.

This is where one of the most immediate problems for IT and security teams shows up: controlling how employees and applications use AI.

During the first wave of ChatGPT and other generative assistants, much of the concern centered on so-called Shadow AI: employees using unauthorized tools and sending code, documents, or company information to external services.

With agents, the problem changes scale.

An agent can have access to Slack, Microsoft 365, Google Workspace, GitHub, CRM, ERP, cloud storage, or databases. Depending on how it’s configured, it may be limited to reading information, or it may also be able to modify it.

So protecting the model is no longer enough. Organizations also have to protect the actions it can carry out on the user’s behalf.

The traditional principles of Identity and Access Management (IAM), least privilege, and permission segregation still apply, but now there’s an additional layer making decisions through natural language.

Prompt injection: when the data contains instructions

Gartner specifically flags prompt injection as one of the risks tied to agents.

The firm expects that by 2029, more than half of successful cyberattacks against AI agents will exploit weaknesses related to access controls and prompt injection.

That’s a forecast, but it helps explain why specialized tools are starting to appear. Efforts like the Open Secure AI Alliance, formed to build open defenses for AI agents, are a direct response to that same risk.

A prompt injection attempts to insert instructions that alter a model’s expected behavior. In simple applications it can come directly from the user, but agents introduce far less obvious scenarios.

An agent can encounter malicious instructions inside a web page, a document, an email, or any other content it has to process.

That’s where so-called indirect prompt injection comes in.

The challenge lies in correctly separating the data the model is supposed to analyze from the instructions it should actually obey.

The situation becomes especially delicate when the agent has tools at its disposal.

If it only generates text, the consequences can be relatively contained. But an agent that can send messages, run commands, modify files, or query private information turns a manipulated model into a potential enterprise security incident.

Permission control then becomes inseparable from the security of the LLM itself.

AI gateways become a new infrastructure layer

One of the most interesting segments for infrastructure teams will be AI gateways.

Gartner expects spending to grow from $251 million in 2026 to $429 million in 2027, an increase of 70.9%.

The rise of this category makes a fair amount of sense.

Early generative applications could connect directly to a single API. Now an organization might simultaneously use models from OpenAI, Anthropic, Google, Mistral, Meta, DeepSeek, or Qwen, alongside models deployed on its own infrastructure.

Even a single application can switch between different LLMs depending on cost, latency, or the characteristics of each request — a pattern already visible in products such as Snowflake’s dynamic model routing for its Cortex AI Gateway.

The gateway sits between applications and that collection of models.

From that position, it can centralize policies, authentication, observability, and restrictions. It can also control which models are authorized, which providers are allowed to receive certain data, or which applications are permitted to use each service.

The idea has similarities to the API gateways that became common as microservices spread, though AI introduces new elements that need to be inspected.

It’s no longer just structured parameters and responses flowing through.

What flows through now includes prompts, potentially massive contexts, documents, images, tool calls, and dynamically generated responses.

An AI gateway can thus become a point where policies are applied before a request reaches the model, and where the response is reviewed afterward.

The rise of model routing also means this layer can take on additional functions. A company can use different models based on price, performance, or availability without letting each application directly manage every credential and provider.

Security, routing, and observability are starting to converge in the same part of the architecture.

Governance will first have to discover what AI actually exists

Another market Gartner expects to grow quickly is AI Governance Platforms, which will go from $275 million to $462 million in 2027.

Before applying any security policy, there’s a seemingly simple question many organizations still can’t answer with precision:

How many AI systems are actually running inside the company?

There can be internally developed applications, assistants embedded in SaaS products, APIs purchased directly by individual departments, open models running on the company’s own servers, and experimental agents deployed by technical teams.

The inventory is just the starting point.

After that, organizations need to identify which model version each application uses, what data it processes, where it runs, who has access, which provider is involved, and which tools it’s allowed to use.

Agents also add relationships between systems.

An agent might use an LLM from one provider, query a database hosted in a different environment, and execute an action through a corporate API. Security has to follow that entire chain.

That’s why Gartner expects existing governance platforms and large enterprise vendors to expand their products to add AI controls.

The software supply chain enters the equation too

Gartner also flags another risk that doesn’t depend directly on prompts: the software supply chain.

Many AI projects are built using a considerable number of external components.

Open models, Python libraries, inference frameworks, agent tooling, MCP servers, connectors, containers, model repositories, and packages downloaded from public registries can all be part of the same application.

The problem of third-party dependencies didn’t start with AI. Log4Shell, attacks on package repositories, and leaked credentials have spent years demonstrating how important it is to control the supply chain.

AI simply adds more pieces to it.

A model downloaded from an external repository is also an artifact that needs to be verified. The same goes for a container used to run inference, or a tool an agent installs to access a service.

As companies deploy more AI on their own infrastructure, the security of the entire stack will matter just as much as protecting the model itself.

Traditional security will still be necessary

The growth of this new industry might give the impression that current tools need to be replaced by a completely different category.

Gartner instead frames it as a combination.

Firewalls, Endpoint Detection and Response (EDR), Security Information and Event Management (SIEM), identity management, API security, data protection, and network controls remain necessary.

A database an agent can access still needs authentication.

An API still needs authorization.

An inference server still needs updates and monitoring.

The difference is that those layers don’t necessarily understand what it means for a model to be receiving a prompt injection, or for an agent to be trying to use a tool in an unexpected way.

That’s where the specialized products Gartner is tracking come in.

The firm also expects market consolidation. In areas like AI Application Security and AI Usage Control, specialized startups are emerging, while in governance and gateways, established enterprise vendors start with an advantage because they already control related parts of the infrastructure.

If the market reaches the roughly $7.7 billion projected for 2028, acquisitions will likely pick up.

Cybersecurity has followed this path many times before: a new attack surface appears, specialized tools emerge, and larger platforms eventually absorb those functions through in-house development or acquisitions.

With AI, that process can play out especially fast.

Companies are moving in just a few years from testing chatbots to deploying agents with access to corporate infrastructure. And the more an agent can do, the more it matters to determine who controls it, what permissions it has, what data it can use, and what happens when someone manages to trick it.

The $4.783 billion Gartner projects for 2027 is, above all, a sign that securing AI is moving past being an experimental function and becoming just another layer of the enterprise technology stack.

Frequently Asked Questions

How much will the AI security market grow in 2027?

Gartner expects growth of 68.7%, from $2.835 billion in 2026 to $4.783 billion in 2027. By 2028, it expects the market to approach $7.7 billion.

What is an AI gateway?

It’s an intermediate layer between applications and AI models that can centralize access, policies, observability, and restrictions on providers and models. Gartner estimates this segment will reach $429 million in 2027.

Why is prompt injection especially concerning for AI agents?

Because an agent can process malicious instructions found in documents, emails, or web pages while also having tools available to take action. Gartner expects access controls and prompt injection to be behind more than half of successful attacks against agents by 2029.

Will these tools replace traditional cybersecurity?

No. Gartner frames it as combining existing defenses with specialized technologies capable of detecting risks specific to AI models and agents.

Source: Open Security

Scroll to Top