Safeguard
Industry Analysis•

How Many AI Agents Are There in 2026? What the Published Numbers Actually Count

There is no census of AI agents. What Microsoft (nearly 40 million agents registered in Agent 365), Salesforce, OpenAI, IDC and Gartner have actually published, what each figure counts, a reproducible count of the official MCP Registry (46,265 servers), and how to count the agents in your own company.

Safeguard Security Team
Security Research
9 min read

Nobody knows how many AI agents exist, because nobody counts them the same way. The largest published figure for agents actually in use comes from Microsoft, which said on 29 July 2026 that its Agent 365 control plane had "nearly 40 million agents registered across tens of thousands of companies". Every other number you'll see measures something different: work done, money earned, tools available, or a forecast.

This post is for security, IT and platform leaders who keep being quoted agent numbers, in board decks, vendor pitches and analyst notes, and want to know what they mean. It covers what counts as an agent, the measures that have actually been published, with dates and who published them, the forecasts and how far apart they are, a count we ran ourselves of the public MCP Registry, and how to count the agents in your own company, which is the number that matters.

The short answer

There is no census of AI agents in 2026. The published figures each count something different: Microsoft reports nearly 40 million agents registered in Agent 365 (29 July 2026); Salesforce reports 7.0 billion "Agentic Work Units" delivered by Agentforce and Slack to date rather than a count of agents (26 August 2026); OpenAI last published a creator count in January 2024, when users had made over 3 million custom GPTs. For the future, an IDC snapshot cited by Microsoft projects 1.3 billion AI agents by 2028, while Gartner predicts that 33% of enterprise software applications will include agentic AI by 2028 and that over 40% of agentic AI projects will be canceled by the end of 2027. The official MCP Registry, which lists tools agents can connect to rather than agents, held 46,265 servers on 19 October 2026.

What counts as an agent

The word covers a wide range. A helpdesk bot built in a low-code tool, a coding assistant that runs tests and opens pull requests, and an autonomous workflow that calls ten APIs can all be called agents. Gartner has a name for the stretching: "agent washing", the rebranding of assistants, robotic process automation and chatbots without real agentic capability. In its June 2025 release, Gartner estimated that only about 130 of the thousands of vendors selling agentic AI are real.

For counting, three distinctions matter more than the definition:

  • Built versus running. Platforms count agents created. Many are tests, copies or one-off experiments that never run again.
  • Agent versus identity. A control plane counts what's registered with it. One workflow can register several agents, and an agent nobody registered isn't counted at all.
  • Agent versus work. Some vendors count actions or tasks completed, which says how busy agents are, not how many there are.

What has actually been published

MeasureFigureWho and whenWhat it counts
Agents registered in Agent 365nearly 40 million, across tens of thousands of companiesMicrosoft, FY26 Q4 earnings call, 29 July 2026Agents registered with one vendor's control plane, two months after launch
Agents managed in Agent 365"tens of millions"Microsoft, FY26 Q3 earnings call, 29 April 2026The same measure, three months earlier
Agentic Work Units7.0 billion to date, 3.2 billion in the quarterSalesforce, Q2 fiscal 2027 results, 26 August 2026Work delivered across Agentforce and Slack, not agents
Custom GPTs createdover 3 millionOpenAI, 10 January 2024Configured chatbots, two months after launch; a January 2024 figure
Organizations investing in agentic AI19% significant, 42% conservative, 8% none, 31% waitingGartner poll of 3,412 webinar attendees, January 2025Intent, not deployments

Salesforce also reports money rather than headcount: Agentforce annual recurring revenue above $1.5 billion in the same release, a figure that from that quarter includes "Slackbot and Headless 360". That's a useful signal of paid adoption, and it isn't a count of agents either.

The Microsoft figure is the closest thing to a census, and it's still one vendor's registry. It counts agents that customers have chosen to register, including ones built in Microsoft's own low-code tools, and it can't see agents built elsewhere.

The forecasts, and how far apart they are

ForecastMade byPublished
1.3 billion AI agents by 2028IDC Info Snapshot (doc US53361825), as cited in Microsoft's Agent 365 session deckMay 2025
33% of enterprise software applications will include agentic AI by 2028, up from less than 1% in 2024Gartner25 June 2025
At least 15% of day-to-day work decisions made autonomously through agentic AI by 2028, up from 0% in 2024Gartner25 June 2025
Over 40% of agentic AI projects canceled by the end of 2027Gartner25 June 2025

These don't contradict each other, because they measure different things. A world with 1.3 billion agents and 40% of projects canceled is entirely possible: agents are cheap to create and easy to abandon. What the forecasts share is that they were all published before most of the 2026 figures above, so check the date before you repeat one.

A count you can reproduce: the MCP Registry

Agents need tools, and the Model Context Protocol (MCP) has become a common way to connect them. The official MCP Registry lists MCP servers that publishers have registered, so it measures the tool supply, not the agent population. Unlike most of the figures above, anyone can count it. Here's the script we used, standard library only:

#!/usr/bin/env python3
"""Count the servers listed in the official MCP Registry (latest version of each),
split by how they're delivered and when they were first published.

Usage: python3 mcp_registry_count.py [output.json]"""
import collections
import json
import sys
import time
import urllib.parse
import urllib.request

BASE = "https://registry.modelcontextprotocol.io/v0/servers?limit=100&version=latest"


def fetch(url, tries=5):
    for attempt in range(tries):
        try:
            req = urllib.request.Request(url, headers={"User-Agent": "mcp-registry-count/1.0"})
            with urllib.request.urlopen(req, timeout=30) as r:
                return json.load(r)
        except Exception as err:
            print(f"retry {attempt + 1}: {err}", file=sys.stderr)
            time.sleep(2 * (attempt + 1))
    raise SystemExit("registry kept failing; try again later")


def main(out=None):
    servers, cursor = [], None
    while True:
        url = BASE + (f"&cursor={urllib.parse.quote(cursor)}" if cursor else "")
        page = fetch(url)
        servers += page.get("servers", [])
        cursor = (page.get("metadata") or {}).get("nextCursor")
        print(f"\r{len(servers)} servers", end="", file=sys.stderr)
        if not cursor:
            break
    print(file=sys.stderr)
    if out:
        json.dump(servers, open(out, "w"))
    meta = [s.get("_meta", {}).get("io.modelcontextprotocol.registry/official", {}) for s in servers]
    status = collections.Counter(m.get("status", "?") for m in meta)
    delivery = collections.Counter()
    for s in servers:
        srv = s["server"]
        kinds = (["remote"] if srv.get("remotes") else []) + sorted({p.get("registryType", "?") for p in srv.get("packages", [])})
        delivery[" + ".join(kinds) or "none listed"] += 1
    print(f"servers (latest version each): {len(servers)}")
    print("status: " + ", ".join(f"{k} {v}" for k, v in status.most_common()))
    print("delivered as:")
    for k, v in delivery.most_common(8):
        print(f"  {k:28} {v}")


if __name__ == "__main__":
    main(sys.argv[1] if len(sys.argv) > 1 else None)

Run on 19 October 2026:

$ python3 mcp_registry_count.py
servers (latest version each): 46265
status: active 45669, deprecated 596
delivered as:
  remote                       27798
  npm                          9391
  pypi                         3886
  remote + npm                 1673
  mcpb                         955
  oci                          738
  none listed                  505
  remote + pypi                275

The registry listed 46,265 servers, 596 of them marked deprecated. Most are offered only as remote endpoints (27,798), while 9,391 are published only as npm packages and 3,886 only on PyPI. The listing is changing quickly: 26,334 servers had their latest version published in September or October 2026. That date belongs to the latest version, not the first one, so it shows activity rather than how many servers are new.

Many servers are never registered, and a registered server says nothing about how many agents use it. Treat the registry as a floor for what's publicly offered, not a count of what's used.

Count the agents in your own company

The global number is trivia. The one that matters is how many agents run inside your company, what each can reach, and who answers for it. A practical first pass:

  1. Start from identities. List service accounts, OAuth apps, API keys and tokens created in the last year, and flag the ones used by an AI tool or agent framework.
  2. Ask the platforms. Low-code agent builders, chat assistants and coding tools usually have an admin view of agents or connectors created by your users.
  3. Read the configs. MCP configuration files (mcp.json and similar) in repositories and on developer machines show which tools agents can call.
  4. Record each one. Owner, purpose, permissions, data reached, and when it was last used. Our guide to agent registry entry fields lists what to capture.
  5. Retire the idle ones. If most agents are experiments, most of your inventory should end up switched off.

MCP servers are often where an agent's reach is decided. Here's Safeguard's interactive walkthrough of putting a guardrail in front of MCP servers:

The fair view

Vendor-reported counts come from companies that sell agent platforms, and forecasts are made by firms whose clients want to know where to spend. That doesn't make the numbers wrong. Microsoft's figure comes from a registry it operates, Salesforce's from usage it bills, and Gartner states its poll's size and date. It does mean every number needs its source, date and definition next to it.

The bigger risk is quoting a forecast as a fact. "1.3 billion agents" was a projection for 2028 published in May 2025, and "40 million registered" was a measured count in one product in July 2026. Both are useful. They answer different questions.

Check yourself

A vendor deck says there are 1.3 billion AI agents. What should you ask?

Whether it's a count or a forecast. The figure comes from an IDC snapshot published in May 2025 that projects 1.3 billion agents by 2028. It isn't a measurement of agents running today.

Why isn't Salesforce's 7.0 billion Agentic Work Units a count of agents?

It counts work delivered by agents across Agentforce and Slack, to date, as of Salesforce's results on 26 August 2026. A small number of busy agents and a large number of idle ones could produce the same total.

The MCP Registry lists tens of thousands of servers. Does that mean tens of thousands of agents?

No. The registry lists tools that agents can connect to, registered by publishers. It says nothing about how many agents use them, and many servers are never registered there.

Never miss an update

Weekly insights on software supply chain security, delivered to your inbox.

Self-healing security runs on Safeguard.

Your first fix PR is minutes away.

No sales call required, even your agent can complete the purchase over MCP.