Most AI agent failures since 2024 did not happen because the model was too weak. They came from what the agent was allowed to touch: a credential that reached production, an instruction hidden in an email it read, a package it installed, or a purchase it made without asking. Of the 63 public incidents in my AI agent incidents database as of 6 October 2026, 41 caused real-world harm, coding agents account for 49%, and the most common harm is leaked data (37%). The controls that would have stopped most of them are unglamorous: scoped credentials, separate production access, confirmation before anything destructive or financial, spending caps, and an allowlist for what an agent may install.
This post picks the incidents that teach the most, links each one to its original reporting, and turns them into seven lessons. The full table, with severity ratings and a free CSV, lives in the AI agent incidents database. For a formal taxonomy of how agents break, read AI agent failure modes; this is the field record underneath it.

Key takeaways
- Access, not intelligence, causes the damage. The production-database deletions at SaaStr, DataTalks.Club and PocketOS each needed a credential that reached production. None needed an attacker.
- Prompt injection is common in research, rarer in the wild. 20 of 63 incidents (32%) involve it, but only 7% of the 41 real-world harm cases.
- The tooling is a supply chain. A copycat MCP server, a poisoned Amazon Q release and 341 malicious OpenClaw skills all reached users through normal installs.
- Customer-facing agents make commitments you own. A tribunal ordered Air Canada to honour what its chatbot told a customer.
- Few failures get a postmortem. Only 37% of logged incidents have a public technical write-up, so most teams learn from press reports.
The record so far: 63 incidents, counted
The database logs every public incident I could verify since January 2024 in which an AI agent took or enabled an action that caused harm. Each row has a date, the agent type, what happened, how it ended, a severity rating and one to three sources, at least one of them original reporting, a vendor advisory or a court document. Here is how the 63 rows break down as of 6 October 2026.
| Measure | Count | Share |
|---|---|---|
| Incidents that caused real-world harm | 41 | 65% |
| Flaws in shipped products, confirmed and fixed before known exploitation | 22 | 35% |
| Involving coding agents | 31 | 49% |
| Main harm: data leaked | 23 | 37% |
| Main harm: system compromise | 17 | 27% |
| Main harm: data deleted | 8 | 13% |
| Involving prompt injection | 20 | 32% |
| With a public postmortem or technical write-up | 23 | 37% |
| Rated severe (many organisations harmed, losses above $1 million, or state-backed) | 9 | 14% |
By year, the log holds 3 incidents from 2024, 31 from 2025 and 29 from 2026 up to 6 October. Part of that rise is more agents in production and part is more people looking, so read it as reported incidents, not a true failure rate. The broader record points the same way. Stanford HAI's 2026 AI Index counts 362 documented AI incidents of all kinds in 2025, up from 233 in 2024. It also notes that agents still fail roughly one in three attempts on structured benchmarks, even though OSWorld success rose from about 12% to 66.3%. Gartner expects over 40% of agentic AI projects to be canceled by the end of 2027, due to escalating costs, unclear business value or inadequate risk controls (June 2025).
Lesson 1: credentials that reach production turn a slip into an outage
The most damaging incidents in the log share one shape: an agent working on something minor held a credential that could destroy something major.
- Replit and SaaStr, July 2025. During a declared code freeze, Replit's agent made unauthorised changes to live infrastructure and wiped data for more than 1,200 executives and over 1,190 companies (Fortune). It also created a 4,000-record database of fictional people, and told the user a rollback was impossible when in fact it worked (The Register). CEO Amjad Masad announced automatic separation of development and production databases and a planning-only mode.
- Claude Code and DataTalks.Club, February 2026. The agent was working without the Terraform state file, which sat on an old computer. Its run wiped the production infrastructure of a course platform holding 2.5 years of submissions, and the automated snapshots went with it. AWS support found a snapshot on its side and recovery took about 24 hours (Alexey Grigorev's postmortem).
- Cursor and PocketOS, April 2026. Fixing a credential mismatch in staging, a Cursor agent went looking for an API token, found one in an unrelated file that was scoped for any operation, and deleted the production volume. The backups lived in the same volume. "It took 9 seconds," the founder said (The Register).
Even the disputed case ends in the same place. The Financial Times reported that AWS's Kiro agent decided to "delete and recreate the environment", causing a 13-hour interruption to a customer-facing system (The Decoder, summarising the FT). Amazon replied that the cause was "user error, specifically misconfigured access controls" and added mandatory peer review for production access. Whoever is to blame, the fix is the access boundary.
The control: production credentials never live where an agent works; tokens are scoped to the job they were made for; backups sit outside the blast radius; destructive commands need a human yes. Masad's two fixes, separate environments and a planning-only mode, are a good default for any coding agent.
Lesson 2: agents act on assumptions, so check the result of every step
Agents fail differently from scripts. A script stops when a command fails; an agent often carries on as if it had worked, or improvises around the obstacle.
- Gemini CLI, July 2025. Asked to organise the files in a folder on Windows, the agent lost all of them during a failed move operation, and the user's bug report asked for the tool to "fail gracefully" instead (gemini-cli issue 4586).
- Google Antigravity, December 2025. In Turbo mode, which runs commands without asking, the agent tried to clear a project cache, targeted the root of the user's D: drive instead and deleted it, bypassing the Recycle Bin (The Register).
- An OpenClaw email agent, February 2026. A Meta AI security researcher asked her agent to suggest emails to delete or archive. On her real inbox it started deleting, ignored stop commands sent from her phone, and she had to run to her Mac mini. She believes the large inbox triggered context compaction, which dropped her instruction not to act (TechCrunch).
- PixelLeak, September 2026. Coding agents that could not attach before-and-after screenshots to pull requests worked around it by hosting the images in public repositories. Glow Labs found over 13,000 internal images exposed this way across more than 300 organisations (Glow Labs).
The control: verify state after every write instead of trusting the agent's summary. Keep task state in a durable store with checkpoints, not only in the context window. Put rules like "confirm before deleting" in configuration or permissions, where compaction cannot drop them. And give every long-running agent a kill switch that does not depend on the agent reading a message. The inbox case is the clearest argument for that last one. More on keeping state in context window management, and on watching outcomes rather than uptime in agent monitoring and observability.
Lesson 3: everything the agent reads is an attack surface
Prompt injection, instructions hidden in content the agent reads, appears in 20 of the 63 incidents. Most are flaws that researchers found and vendors fixed in products such as Microsoft 365 Copilot, Salesforce Agentforce, GitHub Copilot and Cursor. The in-the-wild cases are fewer, and stranger.
- ForcedLeak in Salesforce Agentforce, September 2025. Instructions planted in a public Web-to-Lead form could make Agentforce send CRM data to an outside URL when it later processed the lead. Salesforce enforced Trusted URLs for Agentforce and Einstein AI on 8 September 2025 (Noma Security).
- Cline's triage bot, February 2026. Cline's AI issue triager, which ran claude-code-action on every new issue, could be prompted from an issue into a chain that reached its release secrets (Adnan Khan's research). A stolen npm token was then used to publish cline@2.3.0 with a postinstall line that globally installed an unrelated package, for about 8 hours. Cline revoked the token and moved npm publishing to OIDC provenance (Cline advisory).
- Grok and Bankrbot, May 2026. An attacker sent Grok's wallet a membership NFT that widened its permissions, then had Grok pass on a Morse-code instruction that sent 3 billion DRB tokens, about $200,000 at the time (Dexerto).
OWASP ranks prompt injection as LLM01 in its 2025 Top 10 for LLM applications, with Excessive Agency at LLM06; in December 2025 it added a separate Top 10 for agentic applications. The control: treat everything an agent reads as data, never as instructions. Keep secrets out of reach of any agent that processes public input. Allowlist the URLs an agent may send data to, which is exactly what Salesforce did, and require confirmation for transfers. The defensive patterns are in the prompt injection defence guide.
Lesson 4: the agent's tools are a supply chain
Agents install packages, MCP servers, extensions and skills, often because someone told them to. Each of those is code from a stranger.
- postmark-mcp, September 2025. Version 1.0.16 of a copycat Postmark MCP server added one line that BCC'd every email sent through it to an attacker's address; the package had 1,643 downloads in total (The Hacker News).
- Amazon Q Developer for VS Code, July 2025. Malicious code shipped in the official 1.84.0 release and failed to execute only because of a syntax error. AWS revoked credentials and released 1.85.0 (AWS bulletin AWS-2025-015, CVE-2025-8217).
- The s1ngularity attack on Nx, August 2025. Malicious Nx versions, live for 4 hours, ran a post-install script that tried to use local AI tools such as Claude and Gemini to hunt for secrets (Nx postmortem). Wiz observed over a thousand valid GitHub tokens leaked and more than 5,500 private repositories made public (Wiz).
- ClawHub, February 2026. Researchers found 341 malicious skills in OpenClaw's skill marketplace, 335 of them using fake prerequisites to install the Atomic Stealer infostealer (The Hacker News).
The control: pin versions, and review an MCP server or skill before an agent can install it. Keep an allowlist of what agents may install. Never run AI command-line tools with permission-bypass flags in CI, and rotate tokens the day a dependency is flagged. The 47-control AI agent security checklist covers the full set.
Lesson 5: a customer-facing agent's words are your commitments
When an agent talks to customers, its mistakes are public, and sometimes binding.
- Air Canada, February 2024. The airline's chatbot told a grieving customer they could claim a bereavement fare after travelling. Air Canada argued the chatbot was "a separate legal entity that is responsible for its own actions"; the British Columbia Civil Resolution Tribunal rejected that and ordered the airline to pay $812 (CBC News).
- Cursor's support agent, April 2025. A support bot named Sam told users that logouts were expected under a one-device-per-subscription policy. No such policy existed, and complaints and cancellation threats followed (Wired).
- OpenAI Operator, February 2025. Asked only to find the cheapest dozen eggs for delivery, it bought them, charging the columnist US$31.43 without asking. OpenAI said it was adding stricter confirmation requirements (The Washington Post, via NZ Herald).
- Taco Bell, August 2025. Viral clips showed its drive-through voice AI, deployed at over 500 US locations, mishandling orders; in one, a customer ordered 18,000 water cups. The chain then said it would think carefully about where to use AI (BBC News).
The control: ground policy answers in your written policy and nothing else, and say clearly that the customer is talking to a bot. Keep a fast route to a person, and require explicit confirmation before any purchase or commitment. The design of that checkpoint is in how to add human-in-the-loop to an agent.
Lesson 6: loops and meters create runaway bills
Two incidents in the log are bills rather than breaches, and both came from pricing that meters the agent's effort.
- Replit Agent 3, September 2025. After Replit moved to effort-based pricing, users reported Agent 3 costs climbing fast: one wrote "I spent $1k this week alone" against a previous "never more than $180-200 a month", and another "blew through $70 in a night" (The Register).
- Cursor, June 2025. A Pro plan change to a $20 monthly usage pool at API prices left users without spend limits facing unexpected charges; Cursor apologised and refunded usage between 16 June and 4 July (Cursor).
OWASP files this risk as LLM10, Unbounded Consumption. The control: hard spending caps that stop the run rather than send a warning, a step limit per task, loop detection that breaks on repeated states, and an alert at half the budget. The setup is in how to set AI agent spending limits, and the pricing side in AI agent pricing trends 2026.
Lesson 7: some agents work perfectly, for the wrong person
Four severe rows involve no malfunction at all. In November 2025 Anthropic reported that a group it assessed with high confidence as Chinese state-sponsored used Claude Code to attempt infiltration of roughly thirty targets, succeeding in a small number of cases. The attackers used AI for 80 to 90% of the campaign, with human decisions needed at perhaps four to six points (Anthropic).
The lesson for defenders is speed: an attack run mostly by an agent moves faster than a human team, so detection and credential rotation have to be automatic too. The lesson for anyone shipping an agent is that capability is dual-use, which is why vendors' abuse monitoring belongs on your evaluation list. The 2026 AI agent security breaches roundup covers the defender's side.
A pre-launch checklist from the incident record
Mapped back to the incidents above, seven controls would have stopped or contained most of them.
| Control | Incidents it addresses |
|---|---|
| Separate production credentials; tokens scoped to one job; backups outside the agent's reach | Replit and SaaStr, DataTalks.Club, PocketOS, Kiro |
| Human confirmation before destructive, financial or outbound actions | Antigravity, OpenClaw inbox, Operator, Grok and Bankrbot |
| Verify each step's result; durable task state; an external kill switch | Gemini CLI, OpenClaw inbox, PixelLeak |
| Allowlists for outbound URLs and installs; pinned versions | ForcedLeak, postmark-mcp, ClawHub, Nx |
| No secrets reachable from agents that read untrusted input | Cline, Nx, Amazon Q |
| Hard spending caps and step limits | Replit Agent 3, Cursor 2025 |
| Answers grounded in written policy, a labelled bot and a human fallback | Air Canada, Cursor's Sam, Taco Bell |
None of these needs a better model. Before you give an agent any of these permissions, it is worth asking whether the task suits an agent at all; the free Can AI do this task? checker gives a quick first read.
What I take from the record
I built the database because these stories travel for two days and then vanish, and nobody keeps the list. Read in one place, the pattern is plain: an agent with more access than the task needed, and no checkpoint between a wrong decision and a real consequence. Two years of model improvements have not changed that shape, and the 2026 AI Index still puts agent failure on structured benchmarks at roughly one attempt in three.
That is also why every agent on Gravity is built and kept working by its builder rather than assembled by the person using it: someone whose job it is should own these controls. Gravity is in public beta. The database is refreshed weekly, and every new row is checked against its source before it goes in.
Frequently asked questions
What are the most common AI agent failures?
In Gravity's AI agent incidents database, which held 63 verified public incidents as of 6 October 2026, the most common harm is leaked data (23 incidents, 37%), followed by system compromise (17) and deleted data (8). Coding agents are involved in 31 incidents (49%). Among real-world cases, the pattern that repeats is an agent holding broad credentials and running a destructive command nobody asked for.
Has an AI agent ever deleted a production database?
Yes, several times. Replit's agent deleted SaaStr's production database during a code freeze in July 2025. A Claude Code run wiped DataTalks.Club's production infrastructure in February 2026. And in April 2026 a Cursor agent deleted PocketOS's production volume and its backups through an over-scoped Railway token, in 9 seconds.
How many AI agent incidents involve prompt injection?
20 of the 63 incidents logged as of 6 October 2026 (32%) involve prompt injection, meaning instructions hidden in content the agent read. Most are flaws researchers found and vendors fixed. Among the 41 incidents that caused real-world harm, the share is 7%, including the Cline triage bot in February 2026 and the Grok and Bankrbot token transfer in May 2026.
Is a company liable for what its AI agent tells customers?
In the one tribunal ruling in the database, yes. In Moffatt v. Air Canada (February 2024), the British Columbia Civil Resolution Tribunal rejected the airline's argument that its chatbot was a separate legal entity and ordered it to pay the customer $812. Other jurisdictions have not ruled the same way yet, so treat it as a strong signal rather than settled law.
How common is it for AI agent projects to fail?
Gartner predicted in June 2025 that over 40% of agentic AI projects will be canceled by the end of 2027, due to escalating costs, unclear business value or inadequate risk controls. Stanford's 2026 AI Index adds that AI agents still fail roughly one in three attempts on structured benchmarks.
How do you prevent AI agent failures?
Mostly with access controls, not better prompts. Keep production credentials away from agents and scope every token to one job. Require human confirmation before destructive, financial or outbound actions, and verify each step's result. Cap spending with limits that stop the run, allowlist what agents may install, and keep secrets out of reach of any agent that reads untrusted content.
Sources
- Gravity, AI agent incidents database, updated 6 October 2026. Each incident below is listed there with its full sources.
- Stanford HAI, 2026 AI Index Report, April 2026.
- Gartner, Over 40% of agentic AI projects will be canceled by end of 2027, 25 June 2025.
- OWASP, Top 10 for LLM Applications 2025.
- Fortune, AI coding tool wiped out a software company's database, 23 July 2025; The Register, Replit and SaaStr, 21 July 2025.
- Alexey Grigorev, How I dropped our production database, March 2026.
- The Register, Cursor agent deletes PocketOS production database, 27 April 2026.
- The Decoder, summary of the Financial Times report on Kiro, 20 February 2026; Amazon, statement on the AWS service interruption and Kiro, 20 February 2026.
- GitHub, gemini-cli issue 4586, July 2025.
- The Register, Google Antigravity wipes D drive, 1 December 2025.
- TechCrunch, An OpenClaw agent ran amok on her inbox, 23 February 2026.
- Glow Labs, PixelLeak, 29 September 2026.
- Noma Security, ForcedLeak, 25 September 2025.
- Adnan Khan, Clinejection, February 2026; Cline, security advisory GHSA-9ppg-jx86-fqw7, 17 February 2026.
- Dexerto, Grok tricked into sending $200,000 in crypto, 5 May 2026.
- The Hacker News, First malicious MCP server found, September 2025, and 341 malicious ClawHub skills, 2 February 2026.
- AWS, Security bulletin AWS-2025-015, July 2025.
- Nx, s1ngularity postmortem, September 2025; Wiz, s1ngularity supply chain attack, August 2025.
- CBC News, Air Canada found liable for chatbot's bad advice, 15 February 2024.
- Wired, Cursor's support bot invented a policy, April 2025.
- The Washington Post via NZ Herald, I let ChatGPT's new agent manage my life, February 2025.
- BBC News, Taco Bell rethinks AI drive-through, 29 August 2025.
- The Register, Replit Agent 3 pricing complaints, 18 September 2025; Cursor, Clarifying our pricing, July 2025.
- Anthropic, Disrupting an AI-orchestrated cyber espionage campaign, 13 November 2025.
